Screen friendly/easy on the eyes background

Well, for me the combination

\usepackage{xcolor}
\pagecolor{lightgray!40}

works best. Something closer to sand-color can be achieved by \pagecolor{yellow!20}

Another advice: whatever you do, do not use multicolumn layout! It is so frustrating to move the page up and down...


Some pdf viewers allow you to change the page background color. For example, in xpdf, you can use

xpdf --papercolor "#333333" file.pdf

to view the file with light gray background. (I believe you can also set the papercolor using Xresources).

Similarly, for sumatra pdfviewer you can use

 SumatraPdf  -bg-color 0x333333 file.pdf

to view the file with light gray background. I seem to remember that adobe acrobat also has this option, but I cannot check at the moment.

This method will work regardless of the software used to create the pdf. In addition, you can print the pdf without any changes as well!


Maybe you would be interested in the Solarized color palette. I think the color Solarized base3 (#FDF6E3, the color I used in the left-hand side figure) is better than white for my eyes.

If you want to keep the original paper color white, while viewing it in base3, you can change the paper color (the background color) in some PDF viewers. For instance, in Okular v.0.19.3:

Settings -> Configure Okular... -> Accessibility -> Change colors -> Change Paper Color

This feature was just implemented in the Internal PDF Viewer of TeXstudio too, and will probably be available in the next stable version. Look here.

What you see in your viewer (color #FDF6E3) / The real PDF (color #FFFFFF).

The colors are quite similar, but you can use a tool like Gpick to compare their hex triplets.

If you really want to change the paper color in LaTeX, e.g., when working in drafts, but want to go back to white for the final version:

\documentclass{article}% option [final] disables the creme background.
\usepackage{xcolor}
\usepackage{ifdraft}
\ifoptionfinal{}{\pagecolor[HTML]{FDF6E3}}
\begin{document}
example
\end{document}

P.S.: I wrote a very similar answer in https://tex.stackexchange.com/a/390621/23481