# Does elastic have a timestamp field as part of metadata as to when was the document written to index?

**URL:** https://discuss.elastic.co/t/does-elastic-have-a-timestamp-field-as-part-of-metadata-as-to-when-was-the-document-written-to-index/352449
**Category:** Elasticsearch
**Created:** [February 3, 2024, 12:21am UTC](https://discuss.elastic.co/t/does-elastic-have-a-timestamp-field-as-part-of-metadata-as-to-when-was-the-document-written-to-index/352449 "2024-02-03T00:21:16Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Rachana\_Maniyar](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rachana_maniyar/32/48476_2.png) [@Rachana\_Maniyar](https://discuss.elastic.co/u/Rachana_Maniyar)
#### Post date: [February 3, 2024, 12:21am UTC](https://discuss.elastic.co/t/does-elastic-have-a-timestamp-field-as-part-of-metadata-as-to-when-was-the-document-written-to-index/352449/1 "2024-02-03T00:21:16Z")

</div>

Does elastic have a timestamp field as part of metadata as to when was the document written to index ? current meta fields that i see are only these -

> **[Metadata fields | Elasticsearch Guide \[8.12\] | Elastic](https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-fields.html)**

I have a usecase where the timestamps in the records could be different from when the records are written to the index. Looking for more info here if i can find out the time at which the records are written to index.

Thanks in advance.

---

<div class="post-metadata">

### Author: ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)
#### Post date: [February 3, 2024, 2:32am UTC](https://discuss.elastic.co/t/does-elastic-have-a-timestamp-field-as-part-of-metadata-as-to-when-was-the-document-written-to-index/352449/2 "2024-02-03T02:32:28Z")

</div>

> [@Rachana\_Maniyar](#):
>
> Looking for more info here if i can find out the time at which the records are written to index.

You can use an ingest pipeline to get something like that, the ingest pipeline has a metadata called `_ingest.timestamp` which corresponds to the time when Elasticsearch received the index request for the document.

You would need to copy this field to another field if you want to store it in your document, you can see how in this [example](https://www.elastic.co/guide/en/elasticsearch/reference/current/ingest.html#access-ingest-metadata).

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [March 2, 2024, 2:32am UTC](https://discuss.elastic.co/t/does-elastic-have-a-timestamp-field-as-part-of-metadata-as-to-when-was-the-document-written-to-index/352449/3 "2024-03-02T02:32:54Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
