I'm trying to copy/paste or export a large number of lines from another application to Google Sheets. However, I discovered that when I copy/paste, any newlines are silently removed. When I try to export as CSV (field separator=, Encloser=" Line terminator=\r\n) and import the CSV, the newlines are completely breaking the row and spilling into the next row.

What separator, encloser, and terminator do I need to export the CSV as for Google Sheets to properly put the newlines in the cells themselves?


1 Answer 1


I downloaded a CSV from Google Sheets which contained newlines in a cell and I see the Google separates each line in the CSV by '\r\n' but each individual newline in a cell is only '\n'. In addition, lines containing '\n' need to be quoted. So the answer is:

  • separator: ,
  • encloser: "
  • line terminator: \r\n
  • but also, any new lines in a cell must be '\n' (not '\r', '\r\n' or '\n\r')

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.