CSV Format Specification
RFC 4180 defines CSV standard: fields separated by commas, rows by line breaks (CRLF or LF). Fields containing delimiter, quotes, or line breaks must be enclosed in double quotes. Double quotes within quoted fields are escaped by doubling (""). Optional header row identifies columns. Many implementations extend the spec: different delimiters (semicolon, tab, pipe), varying quote characters, comment lines, escape characters. Encoding typically UTF-8 but legacy files may use Latin-1, Windows-1252, or locale-specific encodings. BOM (Byte Order Mark) detection helps identify encoding.