How to Add Time and Date Overlay in OBS Studio

This article provides a straightforward, step-by-step guide on how to display a localized, real-time date and clock overlay in OBS Studio. You will learn how to use OBS Studio’s built-in Text source combined with its native Lua scripting engine to display your local time and date seamlessly without downloading any third-party software, widgets, or plugins.

Step 1: Create a Text Source

First, you need to create the text element that will display the time and date on your screen.

  1. Open OBS Studio.
  2. In the Sources dock, click the + (Add) button.
  3. Select Text (GDI+) on Windows, or Text (FreeType 2) on Mac/Linux.
  4. Name the source something recognizable, like “Local Time Overlay”, and click OK.
  5. Leave the “Text” field blank for now and click OK. You can customize the font, size, and color here or return to it later.

Step 2: Load the Built-in Date and Time Script

OBS Studio comes pre-packaged with a native Lua script designed specifically for displaying date and time.

  1. In the top menu bar of OBS, click on Tools and select Scripts.
  2. In the Scripts window, click the + (Add) button in the bottom-left corner.
  3. OBS will automatically open its default scripts folder. Select the file named datetime.lua and click Open.

Step 3: Configure the Script Settings

Once the script is loaded, you need to link it to the text source you created in Step 1.

  1. Select datetime.lua from the list of loaded scripts on the left side of the window.
  2. On the right side, locate the Text Source dropdown menu and select your “Local Time Overlay” source.
  3. In the Format String field, input the syntax for how you want your time and date to be displayed.

Customizing Your Time and Date Format

The script uses standard strftime formatting. Here are the most common codes you can use to customize your layout:

Popular format configurations to copy and paste:

Once you enter your preferred format in the box, the text source on your OBS canvas will instantly begin updating in real-time. Close the Scripts window, then position and resize the text layer on your screen as needed.