# Get app version number through code

**URL:** <https://community.thunkable.com/t/get-app-version-number-through-code/1514459>\
**Category:** Questions about Thunkable X\
**Created:** [September 19, 2021, 3:53pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459 "2021-09-19T15:53:25Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![\_mark](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/_mark/32/138459_2.png) [@\_mark](https://community.thunkable.com/u/_mark)\
**Post date:** [September 19, 2021, 3:53pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459/1 "2021-09-19T15:53:25Z")

</div>

I’ve searched the forum and can’t find a question relating to this.  
Is there a way to retrieve the app version number in code, or is hard coding it into a label the only option at the moment?

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [September 19, 2021, 3:55pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459/2 "2021-09-19T15:55:52Z")

</div>

You’ll need to use a label since there is not a block that contains the version number.

---

<div class="post-metadata">

**Author:** ![Dean\_Artis](https://avatars.discourse-cdn.com/v4/letter/d/a8b319/32.png) [@Dean\_Artis](https://community.thunkable.com/u/Dean_Artis)\
**Post date:** [September 19, 2021, 4:02pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459/3 "2021-09-19T16:02:44Z")

</div>

Hardcode “Version 1.0” into your app and store (save) it in the app.

Add the app version to a website or in an online database. When you first create the app it will be “Version 1.0” ie the same as that hardcoded into your app.

When user checks the app version inside the app, fetch the app version from the website or database and compare it to the stored version in your app.

If the stored app version = fetched app version then that’s ok.

If the fetched app version is newer than the stored version you can let the user know a new version is available and they can update to it.

Each time you update the app make sure you increase the app version on the website or in the database. This way your app always fetches the latest version.

---

<div class="post-metadata">

**Author:** ![\_mark](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/_mark/32/138459_2.png) [@\_mark](https://community.thunkable.com/u/_mark)\
**Post date:** [September 19, 2021, 4:13pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459/4 "2021-09-19T16:13:53Z")

</div>

Thanks @tatiang and @Dean_Artis

That’s what I thought. Maybe that’s something Thunkable can add to the screen or device blocks. Forgetting to update the hardcoded version number when compiling could cause issues if your comparing to an outside data variable. Thanks for the valuable input though, it’s appreciated.

Mark

---

<div class="post-metadata">

**Author:** ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)\
**Post date:** [November 8, 2024, 1:15pm UTC](https://community.thunkable.com/t/get-app-version-number-through-code/1514459/5 "2024-11-08T13:15:13Z")

</div>


