1 2 3 4 5
\documentclass{article} \usepackage{datetime2} \begin{document} This PDF was created on \DTMnow. \end{document}