Insert current date and time

shortcuts creation date shortcuts modification date shortcuts comment

Visual Studio Code

  1. Install Insert Date String extension created by Jakub Synowiec.

  2. Insert date and time:

    • Shift⇧-cmd⌘ I (macOS)

    • Ctrl-Shift I (Windows/Linux)

  3. Go to extension settings if you want to change format of inserted date and time and change setting named Insert Date String: Format:

    • YYYY-MM-DD hh:mm:ss (default value) e.g. 2021-12-30 09:07:11

    • YYYY-MM-DD hh:mm:ss ZZZZ (UTC Time offset value included) e.g. 2021-12-30 09:07:52 +0100

  4. Read more in Usage instructions.