👉 In programming, a newline is a character that separates two consecutive lines of text in a document or file. It can be used to separate multiple line sections of text on one page or in one section of an article. Newlines are often used for creating visual breaks between different parts of the document and for making it easier to read and navigate through large documents.