Configure a custom NTP server via Blueprint Advanced Android Settings JSON
Android
Title: Set a custom NTP server on managed devices using Blueprint JSONWhen a managed Android device is syncing time from a public NTP server instead of your organization's internal time source, device clocks can drift out of compliance or fail to reach an NTP server that is blocked by your network firewall. Using the Advanced Android Settings JSON in a Blueprint, you can push a custom NTP server address to any number of devices without touching each one manually or flashing custom firmware.
Why this happens
Android stores its NTP server address as a global system setting (ntp_server). By default, devices point to time.android.com. Esper's Advanced Android Settings JSON lets you write arbitrary global, secure, and system settings directly to the Android Settings provider at Blueprint convergence, overriding the default without requiring a custom ROM.
Before you begin
- Access to the Esper Console with permission to edit and publish Blueprints
- An existing Blueprint, or permission to create one
- The hostname or IP address of your custom NTP server
- At least one test device enrolled in the target group
- Network confirmation that devices can reach your NTP server on UDP port 123
Note: This approach works on standard Android Enterprise and AOSP builds. Heavily customized OEM ROMs may restrict writes to the ntp_server global key. Verify on a test device before rolling out broadly.
Steps
- Open your Blueprint. In the Esper Console, go to Blueprints and open the Blueprint you want to update. If you do not have one yet, select Create Blueprint and complete the initial setup before continuing.
- Navigate to Advanced Android Settings. Inside the Blueprint editor, go to Esper Settings → Advanced Android Settings. A JSON editor will appear. This section lets you write key-value pairs directly to the Android Settings provider, which is how the NTP server address is stored and read by the OS.
-
Add the NTP server configuration. In the JSON editor, enter the following. If you already have other settings in the editor, merge the
"global"array into your existing"settings"object rather than replacing it:
Replace{ "settings": { "global": [ { "key": "ntp_server", "value": "your.custom.ntp.address" } ] } }your.custom.ntp.addresswith your NTP server's hostname or IP address — for example,ntp.internal.corp.comor192.168.1.10. Use a JSON validator to confirm there are no syntax errors (trailing commas, mismatched braces) before saving. - Save and publish the Blueprint. Select Save, then select Publish. A Blueprint left in draft state will not be applied to devices. Publishing is required before the next step.
- Converge the Blueprint to your devices. Go to Devices & Groups → [your group name] → Blueprint → Converge. This pushes the updated Blueprint — including the NTP setting — to every device in the group. Wait for the convergence operation to complete before verifying.
Verify
Verify: Connect to a test device via ADB and run:
adb shell settings get global ntp_server
The output should return exactly the hostname or IP address you entered in the JSON. Also confirm that the device clock displays the correct time. Both checks should pass within a few minutes of convergence completing. You can also review the convergence result in Devices & Groups → [Device Name] → Activity Feed — a successful convergence will show no errors against the Blueprint.
If this doesn't resolve it
Blueprint convergence shows errors
Go to Devices & Groups → [Device Name] → Blueprint and review the convergence status. Confirm the Blueprint was published (not left as a draft) before the Converge action was triggered.
The NTP key is set but time sync is still failing
This is a network issue, not an Esper issue. Verify that the device can reach your NTP server on UDP port 123 by checking your firewall rules and network routing for the device's subnet.
The setting is applied but does not persist after reboot, or is not accepted by the device
Some OEM ROMs use a locked-down Settings provider that restricts writes to global keys. If the setting is confirmed not persisting after a reboot or after Blueprint re-convergence, contact Esper Support. Include the following when you reach out:
- Blueprint ID
- Device group name
- Esper Agent version from Devices & Groups → [Device Name] → Device Info
- Device make, model, and Android version
- Output of
adb shell settings get global ntp_servertaken immediately after reboot
Still need help?
If you're unable to configure your custom NTP server through Blueprint Advanced Android Settings JSON, please submit a support ticket and include your Blueprint JSON configuration, the NTP server details you're trying to set, and any error messages you're encountering.
Please sign in to leave a comment.
Comments
0 comments