---
title: "Simple Precision Time Protocol at Meta"
description: "Simple Precision Time Protocol (SPTP) replaces the subscription-based unicast PTPv2 exchange with a stateless, client-driven three-packet exchange: a delay request (flagged with PTP profile Specific 1), a sync carrying T4, and a followup/announce carrying T1 and CF1."
url: "https://swe.quest/articles/simple-precision-time-protocol-at-meta-1f4dfeb134554941"
canonical: "https://engineering.fb.com/2024/02/07/production-engineering/simple-precision-time-protocol-sptp-meta/"
source: "Meta Engineering"
published: "2024-02-07"
difficulty: "hard"
kind: "Deep dive"
reading_minutes: 9
tags: ["time-clocks","networking","datacenters","performance"]
---

# Simple Precision Time Protocol at Meta

A post on [Meta Engineering](https://swe.quest/sources/meta.md), published 2024-02-07, 9 min read, Deep dive. Original: [https://engineering.fb.com/2024/02/07/production-engineering/simple-precision-time-protocol-sptp-meta/](https://engineering.fb.com/2024/02/07/production-engineering/simple-precision-time-protocol-sptp-meta/)

## Summary

Simple Precision Time Protocol (SPTP) replaces the subscription-based unicast PTPv2 exchange with a stateless, client-driven three-packet exchange: a delay request (flagged with PTP profile Specific 1), a sync carrying T4, and a followup/announce carrying T1 and CF1. Standard two-step PTP formulas then give path delay and offset. Because the client drives the exchange, it can poll several servers at once and combine them into a clock ensemble. That ensemble rejects outliers using Chauvenet's criterion over 400 samples and weights the remaining clocks by inverse variance. At Meta scale SPTP matches ptp4l precision while cutting CPU by over 40%, memory by 70% and network traffic by 50%, at the cost of losing subscription signaling and authentication.

Written by swe.quest, not by the author.

**Difficulty:** Hard: written for specialists in the field

## Topics

- [Time & clocks](https://swe.quest/tags/time-clocks.md) (Distributed systems)
- [Networking](https://swe.quest/tags/networking.md) (Infrastructure)
- [Datacenters](https://swe.quest/tags/datacenters.md) (Infrastructure)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)

## Prerequisites

- PTP two-step exchange
- clock synchronization basics
- basic statistics

## Keywords

SPTP, Precision Time Protocol, PTPv2, IEEE 1588, ptp4l, fbclock, Chauvenet's criterion

## Related posts

- [How Precision Time Protocol is being deployed at Meta](https://swe.quest/articles/how-precision-time-protocol-is-being-deployed-at-meta-6d56b79aabe69525.md): Meta Engineering · 2022-11-21 · Hard · 27 min read · Time & clocks, Networking, Datacenters, Hardware, Consistency models
  Meta replaced NTP with Precision Time Protocol across its data centers to get nanosecond-level clock sync.
- [PTP: Timing accuracy and precision for the future of computing](https://swe.quest/articles/ptp-timing-accuracy-and-precision-for-the-future-of-computing-7cb5bf24683b59a5.md): Meta Engineering · 2022-11-21 · Easy · 8 min read · Time & clocks, Datacenters, Networking, Open source
  Meta is rolling out Precision Time Protocol (PTP) across its data centers to replace NTP, moving clock synchronization precision from milliseconds to nanoseconds.
- [How Precision Time Protocol handles leap seconds](https://swe.quest/articles/how-precision-time-protocol-handles-leap-seconds-7f6fcf3729d9faf4.md): Meta Engineering · 2025-02-03 · Medium · 3 min read · Time & clocks, Datacenters, Distributed systems
  Meta handles leap seconds for its nanosecond-precision PTP service by self-smearing inside the fbclock library, which shifts its returned Window of Uncertainty {earliest\_ns, latest\_ns} by 1 ns every 62.5 µs.
- [Open-sourcing a more precise time appliance](https://swe.quest/articles/open-sourcing-a-more-precise-time-appliance-d4216f5f1f5059e9.md): Meta Engineering · 2021-08-11 · Hard · 12 min read · Time & clocks, Hardware, Networking, Open source, Linux
  Meta built and open-sourced the Time Card, a PCIe card combining a multiband GNSS receiver, a miniaturized atomic clock and an FPGA time engine that turns a commodity x86 server with a hardware-timestamping NIC into an NTP/PTP Stratum 1 time appliance.
- [It’s time to leave the leap second in the past](https://swe.quest/articles/it-s-time-to-leave-the-leap-second-in-the-past-9e11ae3896edcf86.md): Meta Engineering · 2022-07-25 · Medium · 6 min read · Time & clocks, Distributed systems, Resilience
  Leap seconds do more harm than good for modern computing, and Meta backs an industry push to freeze them at the current 27.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
