# What is the maximum number of characters in a Calc cell? [closed]

In LibreOffice Calc, what is the maximum number of characters in a cell? (In comparison: the xls format has 32,767 characters, and it seems .xlsx also has that limit). I'd like to programmatically create Calc files and would like to know the limit (if any) and whether it is likely to change.

edit retag reopen merge delete

### Closed for the following reason the question is answered, right answer was accepted by Alex Kemp close date 2020-08-08 23:30:05.168139

How to increase cell maximum length 32768 to 50000

( 2017-09-19 12:51:54 +0100 )edit

Sort by » oldest newest most voted

more

The Q&A topic linked here is very old and the given information is no longer valid.

( 2020-05-23 16:53:22 +0100 )edit

Reopened for... The answers to this question formerly given are no longer valid.

For many versions the maximum number of characters per Cal cell was 65535 (=2^15 - 1) (=2^16 - 1) [rectified 2020-05-23].

As of today, tested with LibreOffice V 6.3.3, there is no longer a relevant limit to that number.
I couldn't find release notes for any version clearly stating the number, but got experimentally that it now is 268435455 (= 2^28 - 1). This means you can easily keep the text string of all "The Song of Ice and Fire" in a single cell of a Calc spreadsheet.
You may, however, get "bad allocation" problems If you try to come near that maximum with many cells or to work with such a cell in a formula needing to move the string to memory..

more

Some spreadsheet functions though may still be limited to process only up to 64k characters per cell.

( 2020-05-26 02:22:43 +0100 )edit

This is not correct. The limit is somewhere under 1,316,350. That is the character count in Writer for a log file I tried to open in Calc and failed because the cell character limit was exceeded. It was exceeded because calc fails to continue to parse the delimiter after 108 lines for some reason and puts the rest in one cell.

more

( 2020-04-13 14:23:18 +0100 )edit

Thanks for that, bummer the FAQ doesn't seem to come up in searches. Now if I could figure out why it stops parsing the delimiter...

( 2020-04-13 14:32:35 +0100 )edit

Probably the data is malformed for CSV and opens a quoted field that is never closed, thus the remainder correctly is all read into one cell. In the raw file search for a sequence of ," (if the field separator is comma) and see if that quoted field is closed, i.e. either by ", or a single " at line end.

( 2020-05-26 02:20:33 +0100 )edit