# Filename to Tag

**URL:** <https://community.mp3tag.de/t/filename-to-tag/19035>\
**Category:** Support\
**Created:** [June 9, 2017, 10:48pm UTC](https://community.mp3tag.de/t/filename-to-tag/19035 "2017-06-09T22:48:34Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![CyberMauher](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/c/e19adc/32.png) [@CyberMauher](https://community.mp3tag.de/u/CyberMauher)\
**Post date:** [June 9, 2017, 10:48pm UTC](https://community.mp3tag.de/t/filename-to-tag/19035/1 "2017-06-09T22:48:34Z")

</div>

Hi all, I need convert full path of filename to album tag field.

For example:  
"D:\Music\2015\Sven Väth\Eats Everything - Vertigo.mp3" -\>  
album: Music\2015\Sven Väth (including backslash)

How to I do this?

---

<div class="post-metadata">

**Author:** ![DetlevD](https://community.mp3tag.de/user_avatar/community.mp3tag.de/detlevd/32/123_2.png) [@DetlevD](https://community.mp3tag.de/u/DetlevD)\
**Post date:** [June 10, 2017, 5:46am UTC](https://community.mp3tag.de/t/filename-to-tag/19035/2 "2017-06-10T05:46:44Z")

</div>

> [@CyberMauher](#):
>
> Hi all, I need convert full path of filename to album tag field. For example:  
> "D:\Music\2015\Sven Väth\Eats Everything - Vertigo.mp3" -\>  
> album: Music\2015\Sven Väth (including backslash)  
> How to I do this?

Mp3tag offers several ways to reach the goal, here is one proposal.

Convert "Tag-Tag"  
Field: ALBUM  
Formatstring: $replace('^'%\_path%'$','^D:',,''%\_filename\_ext%'$',)  
Result: Music\2015\Sven Väth

Replace also the backslashes ...  
Formatstring: $replace('^'%\_path%'$','^C:',,''%_filename\_ext%'$',,'','_')  
Result: Music\_2015\_Sven Väth

DD.20170610.0946.CEST, DD.20170611.0705.CEST

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [February 9, 2026, 12:26pm UTC](https://community.mp3tag.de/t/filename-to-tag/19035/3 "2026-02-09T12:26:51Z")

</div>


