I really don't recommend the following, but just posting it to give you an idea of what goes on.
To the underlying TeX typesetting engine, the page is (to a rough approximation) a bunch of paragraphs, each broken into lines according to a line-breaking algorithm (even the section header is in some sense a "paragraph"). TeX has a parameter called \leftskip which is a space ("glue") that it inserts at the beginning of each line. So you could set this to some positive parameter globally, and set it back to zero for section headers.
\documentclass{article}
\usepackage{lipsum}
\begin{document}
\leftskip=15em
\lipsum[1]
\section{\leftskip=0pt First section}
\lipsum[6-7]
\subsection{\leftskip=0pt First subsection}
\lipsum[11-12]
\end{document}

Again, I don't recommend doing the above in a real document (at minimum you probably want to change the actual definition of \section and \subsection (etc.) instead of typing \leftskip=0pt in each of them, change the margins of the document so that not so much space is wasted, etc).
indentfirst? See No indent in the first paragraph in a section? – Werner Jan 26 '17 at 21:55\leftskip, the glue inserted at the beginning of every line in a paragraph. (There's probably other ways, like changing where the page is and making section titles stick out into the putative left margin.) – ShreevatsaR Jan 26 '17 at 21:59