{"id":13160,"date":"2026-09-26T07:35:00","date_gmt":"2026-09-26T05:35:00","guid":{"rendered":"https:\/\/www.lukaswojcik.com\/blog\/?p=13160"},"modified":"2026-09-25T15:07:51","modified_gmt":"2026-09-25T13:07:51","slug":"tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them","status":"publish","type":"post","link":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/","title":{"rendered":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them"},"content":{"rendered":"<p>A single click produces a timestamp in the browser, another in the tag manager, a third in the analytics export and a fourth in the advertising platform it is forwarded to. All four describe the same moment. None of them is written the same way.<\/p>\n<p>Most of the confusion resolves by counting digits. The part that does not is a day boundary, and it is worth knowing about before a report is compared against another one.<\/p>\n<figure class=\"lw-diagram\">\n<img src=\"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/diagrams\/zeitstempel-umrechnen-en.png?v=20260925\" width=\"1120\" height=\"580\" decoding=\"async\" loading=\"lazy\"\n     alt=\"Five timestamp formats with an example value and a digit count each, above a time axis showing an event at half past one at night that falls on two different dates depending on the convention\"><figcaption>The same moment in five notations. The axis below shows the case in which two of them disagree about the date.<\/figcaption><\/figure>\n<h2>Five Formats That Meet in One Stack<\/h2>\n<p>All of them count from the same zero point: midnight on 1 January 1970, in UTC. What differs is the unit and the packaging.<\/p>\n<table style=\"width:100%;border-collapse:collapse;table-layout:auto;\">\n<thead>\n<tr>\n<th style=\"white-space:nowrap;vertical-align:top;\">Format<\/th>\n<th style=\"white-space:nowrap;vertical-align:top;\">Example<\/th>\n<th style=\"vertical-align:top;\">Where it appears<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"white-space:nowrap;vertical-align:top;\">Seconds<\/td>\n<td>1790465400<\/td>\n<td>Meta CAPI event_time, most REST APIs<\/td>\n<\/tr>\n<tr>\n<td style=\"white-space:nowrap;vertical-align:top;\">Milliseconds<\/td>\n<td>1790465400000<\/td>\n<td>Date.now(), gtm.start, most JavaScript<\/td>\n<\/tr>\n<tr>\n<td style=\"white-space:nowrap;vertical-align:top;\">Microseconds<\/td>\n<td>1790465400000000<\/td>\n<td>GA4 BigQuery event_timestamp<\/td>\n<\/tr>\n<tr>\n<td style=\"white-space:nowrap;vertical-align:top;\">ISO 8601<\/td>\n<td>2026-09-27T01:30:00+02:00<\/td>\n<td>Logs, Search Console API, most exports<\/td>\n<\/tr>\n<tr>\n<td style=\"white-space:nowrap;vertical-align:top;\">Date only<\/td>\n<td>20260927<\/td>\n<td>GA4 event_date, BigQuery table suffix<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p>The first three are unambiguous: they are a number of units since a fixed point, and they contain no time zone because they do not need one. The fourth is unambiguous as long as it carries an offset &#8211; the <code>+02:00<\/code> at the end is what makes it a moment rather than a description.<\/p>\n<p>The fifth is different in kind. A date without a time is not a moment but a range of twenty-four hours, and which twenty-four hours depends on a time zone that is not written anywhere in the value.<\/p>\n<h2>Telling Them Apart by Counting Digits<\/h2>\n<p>For a number found in a log, in an export or in a payload, the length settles it.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>10 digits   seconds        1790465400          until the year 2286\n13 digits   milliseconds   1790465400000\n16 digits   microseconds   1790465400000000\n 8 digits   date           20260927            not a moment at all<\/code><\/pre>\n<p>Two mistakes come out of ignoring this, and both produce a result that looks plausible. Reading milliseconds as seconds moves the date to the year 58 707 &#8211; which is obviously wrong and therefore harmless. Reading seconds as milliseconds moves it to 21 January 1970, which is not obviously wrong at all and appears in a report as a tiny bar at the far left of every chart.<\/p>\n<p>A guard clause is three lines and worth having wherever a value arrives from outside.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>def zu_sekunden(wert):\n    z = len(str(int(wert)))\n    if z == 16: return int(wert) \/ 1_000_000\n    if z == 13: return int(wert) \/ 1_000\n    if z == 10: return int(wert)\n    raise ValueError(f\"unbekanntes Zeitformat mit {z} Stellen: {wert}\")<\/code><\/pre>\n<h2>The Day That Is Not the Same Day<\/h2>\n<p>The GA4 BigQuery export carries both a moment and a date, and they use different conventions.<\/p>\n<p><code>event_timestamp<\/code> is microseconds since the epoch, and therefore UTC. <code>event_date<\/code> is a string of the form <code>YYYYMMDD<\/code> in the reporting time zone of the property. For a property set to Berlin, every event between midnight and two in the morning local time therefore carries a date one day ahead of what its own timestamp says in UTC.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>An event on 27.09.2026 at 01:30 Berlin time\n\nevent_date                                          20260927\nDATE(TIMESTAMP_MICROS(event_timestamp))           2026-09-26\nDATE(TIMESTAMP_MICROS(event_timestamp),\n     \"Europe\/Berlin\")                             2026-09-27<\/code><\/pre>\n<p>This is not a bug and it cannot be switched off. It is the reason two queries over the same table can return different daily totals, and the difference is always the same size: the events of the first one or two hours of each day.<\/p>\n<p>The rule that follows is short. Grouping by day uses either <code>event_date<\/code> throughout or <code>DATE(..., \"Europe\/Berlin\")<\/code> throughout, never a mixture &#8211; and a query that joins two tables has to use the same convention on both sides. The table suffix <code>_TABLE_SUFFIX<\/code> follows <code>event_date<\/code>, which means a date filter on the suffix and one on the converted timestamp select different rows.<\/p>\n<h2>Converting in BigQuery<\/h2>\n<p>Three functions cover every case, and each takes the unit in its name.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>SELECT\n  event_timestamp,\n  TIMESTAMP_MICROS(event_timestamp)                       AS moment_utc,\n  DATETIME(TIMESTAMP_MICROS(event_timestamp),\n           \"Europe\/Berlin\")                               AS ortszeit,\n  DATE(TIMESTAMP_MICROS(event_timestamp), \"Europe\/Berlin\") AS tag_lokal,\n  FORMAT_TIMESTAMP(\"%FT%T%Ez\",\n                   TIMESTAMP_MICROS(event_timestamp),\n                   \"Europe\/Berlin\")                       AS iso_mit_versatz,\n  UNIX_SECONDS(TIMESTAMP_MICROS(event_timestamp))         AS sekunden\nFROM `projekt.analytics_123456789.events_*`\nWHERE _TABLE_SUFFIX = \"20260927\"\nLIMIT 10;<\/code><\/pre>\n<p>The distinction between <code>TIMESTAMP<\/code> and <code>DATETIME<\/code> is the one worth internalising. A <code>TIMESTAMP<\/code> is a moment and knows what it is; a <code>DATETIME<\/code> is a wall-clock reading without a zone, and converting a timestamp into one is where the zone information is deliberately dropped. Storing a <code>DATETIME<\/code> and reading it back somewhere else is how an hour disappears.<\/p>\n<p>In the other direction, a string becomes a timestamp only with a stated format, and the format string is where an offset is either read or invented.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>PARSE_TIMESTAMP(\"%FT%T%Ez\", \"2026-09-27T01:30:00+02:00\")   -- korrekt\nPARSE_TIMESTAMP(\"%FT%T\",     \"2026-09-27T01:30:00\")        -- als UTC gelesen<\/code><\/pre>\n<h2>The Windows That Reject a Timestamp<\/h2>\n<p>Two receiving systems check the value rather than just storing it, and both fail in a way that is easy to miss.<\/p>\n<p>The Meta Conversions API accepts an <code>event_time<\/code> within the last seven days. An event older than that is rejected, and a batch upload of historical conversions therefore silently loses everything beyond the window &#8211; the response reports how many events were received, not how many were kept. The check is the number of events in the response against the number sent.<\/p>\n<p>A timestamp in the future is the other half of the same rule, and it happens more often than the past one: a server whose clock runs a few minutes fast produces events that the platform declines. Which means a failing conversion upload is worth investigating as a clock problem before it is investigated as a data problem.<\/p>\n<p>Offline conversion uploads to advertising platforms usually want a local time with an explicit offset rather than an epoch value.<\/p>\n<pre class=\"wp-block-kevinbatdorf-code-block-pro\"><code>2026-09-27 01:30:00+02:00<\/code><\/pre>\n<p>The offset is not decoration. Without it the platform applies the account time zone, and an account configured in a different zone from the shop shifts every conversion by the difference &#8211; which shows up as conversions attributed to the wrong day and, at a month boundary, to the wrong month.<\/p>\n<h2>The Two Ambiguities That Cannot Be Fixed Afterwards<\/h2>\n<p>Everything above is a conversion. These two are losses, and the only remedy is not to create them.<\/p>\n<p>The first is a local time without an offset. <code>2026-09-27 01:30:00<\/code> is not a moment &#8211; it is a moment in some zone, and if the zone was not written down, no later processing can recover it. A guess is possible and is a guess: the same string can be two moments an hour apart.<\/p>\n<p>The second is the changeover night. When the clocks go back, the hour between two and three in the morning happens twice, and a local time inside it is genuinely ambiguous even with the zone known. An offset resolves it, because the two passes have different offsets. A zone name alone does not.<\/p>\n<p>Both disappear if values are stored as UTC and converted only for display. That is a one-line rule that sounds obvious and is broken constantly, because a local time is what a person wants to read &#8211; and the fix is to convert at the point of reading rather than at the point of writing.<\/p>\n<div class=\"lw-faq\">\n<h2>Questions and answers<\/h2>\n<h3>A value has 19 digits. What is it?<\/h3>\n<p>Most likely nanoseconds since the epoch. This format is used by OpenTelemetry, for example, and by the UnixNano function in Go; in a tracking stack it mainly turns up in server and log data. The guard clause rightly rejects it instead of guessing, and it can be extended by one line for 19 digits with the divisor <code>1_000_000_000<\/code>.<\/p>\n<h3>Can JavaScript handle 16-digit microseconds without loss?<\/h3>\n<p>Today, yes, but only just. JavaScript stores numbers as double-precision floating-point values, which represent integers exactly only up to 9,007,199,254,740,991 (<code>Number.MAX_SAFE_INTEGER<\/code>). A microsecond value from 2026, at 1,790,465,400,000,000, is about five times smaller; counted in microseconds, the limit reaches into the year 2255.<\/p>\n<p>Nanoseconds, by contrast, lie far beyond it. A 19-digit value loses its last digits when read with <code>JSON.parse<\/code>, without any error being raised. Where such values are needed in JavaScript, they are best read as strings and converted with <code>BigInt<\/code>, or divided down to milliseconds on the server beforehand.<\/p>\n<h3>Why not simply set the property&#8217;s time zone to UTC?<\/h3>\n<p>That removes the difference between event_date and the timestamp but moves the problem somewhere else. Every daily report in GA4 then starts at midnight UTC, which for a shop in Berlin means one in the morning in winter and two in the morning in summer. A purchase at half past midnight counts towards the previous day, and daily figures no longer match the till, the inventory system and the ad accounts that work in local time.<\/p>\n<p>Then there is the change itself. A new reporting time zone applies only to data from the moment of the change; earlier days stay as they were. The day of the change is therefore shorter or longer than twenty-four hours, and a time series spanning the change puts Berlin days next to UTC days.<\/p>\n<p>The rule from the article holds up better: the property keeps the zone the business works in, and every query commits to one convention. Grouping by Berlin days in BigQuery then has the same day boundaries as the interface, and grouping by UTC is a deliberate choice of a different day.<\/p>\n<h3>How can a server clock be confirmed as the cause of a rejected upload?<\/h3>\n<p>With two checks. On the server itself, <code>timedatectl<\/code> on Linux shows whether the clock is synchronised with a time server; if the line System clock synchronized reads no, a drifting clock is likely. The second check needs no access to the operating system: every HTTP response from the platform carries its server&#8217;s time in the <code>Date<\/code> header, and comparing it with the local time at the same moment shows the offset to within about a second.<\/p>\n<p>If the offset is in the range of minutes, it disappears as soon as synchronisation with a time server is running. Events already sent with the wrong time and rejected then have to be sent again with a corrected timestamp, as long as they are still inside the seven-day window.<\/p>\n<\/div>\n<div class=\"lw-quellen\">\n<h2>Sources<\/h2>\n<ul>\n<li><a href=\"https:\/\/www.rfc-editor.org\/rfc\/rfc3339.html\" target=\"_blank\" rel=\"noopener noreferrer\">RFC 3339: Date and Time on the Internet<\/a><\/li>\n<\/ul>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>Seconds, milliseconds, microseconds, an ISO string and a date without a time zone all describe the same moment and are not interchangeable. Counting the digits identifies four of them &#8211; and the fifth is where a day goes missing.<\/p>\n","protected":false},"author":1,"featured_media":13261,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[113],"tags":[91333,91144,91258,91219],"class_list":["post-13160","post","type-post","status-publish","format-standard","hentry","category-tutorials","tag-bigquery","tag-devops","tag-google-analytics-4","tag-tutorial"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog<\/title>\n<meta name=\"description\" content=\"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog\" \/>\n<meta property=\"og:description\" content=\"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/\" \/>\n<meta property=\"og:site_name\" content=\"Lukas Wojcik - Blog\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-26T05:35:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1200\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Lukas Wojcik\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Lukas Wojcik\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"9 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/\"},\"author\":{\"name\":\"Lukas Wojcik\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#\\\/schema\\\/person\\\/895f7604f9b6b71aad9bba33af28d0f9\"},\"headline\":\"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them\",\"datePublished\":\"2026-09-26T05:35:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/\"},\"wordCount\":1555,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#\\\/schema\\\/person\\\/895f7604f9b6b71aad9bba33af28d0f9\"},\"image\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/08\\\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png\",\"keywords\":[\"BigQuery\",\"DevOps\",\"Google Analytics 4\",\"Tutorial\"],\"articleSection\":[\"Tutorials\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/\",\"url\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/\",\"name\":\"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/08\\\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png\",\"datePublished\":\"2026-09-26T05:35:00+00:00\",\"description\":\"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/08\\\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png\",\"contentUrl\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/08\\\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png\",\"width\":1200,\"height\":630,\"caption\":\"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/en\\\/digital-analytics\\\/tutorials\\\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/\",\"name\":\"Lukas Wojcik - Blog\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#\\\/schema\\\/person\\\/895f7604f9b6b71aad9bba33af28d0f9\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/#\\\/schema\\\/person\\\/895f7604f9b6b71aad9bba33af28d0f9\",\"name\":\"Lukas Wojcik\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/07\\\/lw-x2.jpg\",\"url\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/07\\\/lw-x2.jpg\",\"contentUrl\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/07\\\/lw-x2.jpg\",\"width\":424,\"height\":636,\"caption\":\"Lukas Wojcik\"},\"logo\":{\"@id\":\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\\\/wp-content\\\/uploads\\\/2026\\\/07\\\/lw-x2.jpg\"},\"sameAs\":[\"https:\\\/\\\/www.lukaswojcik.com\\\/blog\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog","description":"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/","og_locale":"en_US","og_type":"article","og_title":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog","og_description":"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.","og_url":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/","og_site_name":"Lukas Wojcik - Blog","article_published_time":"2026-09-26T05:35:00+00:00","og_image":[{"width":1200,"height":630,"url":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png","type":"image\/png"}],"author":"Lukas Wojcik","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Lukas Wojcik","Est. reading time":"9 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#article","isPartOf":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/"},"author":{"name":"Lukas Wojcik","@id":"https:\/\/www.lukaswojcik.com\/blog\/#\/schema\/person\/895f7604f9b6b71aad9bba33af28d0f9"},"headline":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them","datePublished":"2026-09-26T05:35:00+00:00","mainEntityOfPage":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/"},"wordCount":1555,"commentCount":0,"publisher":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/#\/schema\/person\/895f7604f9b6b71aad9bba33af28d0f9"},"image":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#primaryimage"},"thumbnailUrl":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png","keywords":["BigQuery","DevOps","Google Analytics 4","Tutorial"],"articleSection":["Tutorials"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/","url":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/","name":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them - Lukas Wojcik - Blog","isPartOf":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#primaryimage"},"image":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#primaryimage"},"thumbnailUrl":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png","datePublished":"2026-09-26T05:35:00+00:00","description":"Telling the five formats apart by their digit count, converting them in BigQuery, and the day boundary where event_date and event_timestamp disagree.","breadcrumb":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#primaryimage","url":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png","contentUrl":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/08\/hero-13160-tutorial-the-five-timestamp-formats-in-a.png","width":1200,"height":630,"caption":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them"},{"@type":"BreadcrumbList","@id":"https:\/\/www.lukaswojcik.com\/blog\/en\/digital-analytics\/tutorials\/tutorial-the-five-timestamp-formats-in-a-tracking-stack-and-how-to-convert-between-them\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.lukaswojcik.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Tutorial: The Five Timestamp Formats in a Tracking Stack and How to Convert Between Them"}]},{"@type":"WebSite","@id":"https:\/\/www.lukaswojcik.com\/blog\/#website","url":"https:\/\/www.lukaswojcik.com\/blog\/","name":"Lukas Wojcik - Blog","description":"","publisher":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/#\/schema\/person\/895f7604f9b6b71aad9bba33af28d0f9"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.lukaswojcik.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/www.lukaswojcik.com\/blog\/#\/schema\/person\/895f7604f9b6b71aad9bba33af28d0f9","name":"Lukas Wojcik","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/07\/lw-x2.jpg","url":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/07\/lw-x2.jpg","contentUrl":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/07\/lw-x2.jpg","width":424,"height":636,"caption":"Lukas Wojcik"},"logo":{"@id":"https:\/\/www.lukaswojcik.com\/blog\/wp-content\/uploads\/2026\/07\/lw-x2.jpg"},"sameAs":["https:\/\/www.lukaswojcik.com\/blog"]}]}},"_links":{"self":[{"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/posts\/13160","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/comments?post=13160"}],"version-history":[{"count":2,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/posts\/13160\/revisions"}],"predecessor-version":[{"id":20621,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/posts\/13160\/revisions\/20621"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/media\/13261"}],"wp:attachment":[{"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/media?parent=13160"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/categories?post=13160"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.lukaswojcik.com\/blog\/wp-json\/wp\/v2\/tags?post=13160"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}