# Painless script to convert from HEX to string

**URL:** https://discuss.elastic.co/t/painless-script-to-convert-from-hex-to-string/343134
**Category:** Elasticsearch
**Tags:** painless
**Created:** [September 15, 2023, 11:12am UTC](https://discuss.elastic.co/t/painless-script-to-convert-from-hex-to-string/343134 "2023-09-15T11:12:40Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![alextg](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/alextg/32/137075_2.png) [@alextg](https://discuss.elastic.co/u/alextg)
#### Post date: [September 15, 2023, 11:12am UTC](https://discuss.elastic.co/t/painless-script-to-convert-from-hex-to-string/343134/1 "2023-09-15T11:12:40Z")

</div>

Hi,  
I need to convert an HEX field to string using Painless script. Please advise how can this be achieved.

---

<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: [October 13, 2023, 11:13am UTC](https://discuss.elastic.co/t/painless-script-to-convert-from-hex-to-string/343134/2 "2023-10-13T11:13:02Z")

</div>

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