# Replace the / in tag when converting to filename

**URL:** https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901
**Category:** Support
**Created:** [September 30, 2025, 8:06am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901 "2025-09-30T08:06:25Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![djned](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/b4bc9f/32.png) [@djned](https://community.mp3tag.de/u/djned)
#### Post date: [September 30, 2025, 8:06am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/1 "2025-09-30T08:06:25Z")

</div>

Hello, I ran into a bit of an issue, I am trying to rename few folders that have mp3’s. The tag contains / between the artist and featured artist, but when converting to filename, the / is removed. I want to rename the files (e.g. tag is Dj Snake/J Balvin - Noventa) in this format : Dj Snake & J Balvin -Noventa. Do you know what kind of string I can use? Thank you in advance.

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [September 30, 2025, 8:19am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/2 "2025-09-30T08:19:27Z")

</div>

> [@djned](#):
>
> but when converting to filename, the / is removed

Unfortunately, you do not tell us, which function you use and which format string you use to rename the files.

In general

> [@djned](#):
>
> tag is Dj Snake/J Balvin - Noventa) in this format : Dj Snake & J Balvin -Noventa

Try instead of the plain %artist%:  
`$replace(%artist%,/, & )`

---

<div class="post-metadata">

### Author: ![djned](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/b4bc9f/32.png) [@djned](https://community.mp3tag.de/u/djned)
#### Post date: [September 30, 2025, 8:36am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/3 "2025-09-30T08:36:02Z")

</div>

I am using the function Tag - Filename with the string %artist% - %title%

 ![image](https://community.mp3tag.de/uploads/default/original/3X/8/0/80d36c86006b941274e96328e1c60ed9f9560637.png)

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [September 30, 2025, 8:47am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/4 "2025-09-30T08:47:02Z")

</div>

![grafik](https://community.mp3tag.de/uploads/default/original/3X/3/6/36b33ac5184761f24c327d0fac5bfa7f9f3cb6c5.png)  
... and? did you try my suggestion?

---

<div class="post-metadata">

### Author: ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)
#### Post date: [September 30, 2025, 8:48am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/5 "2025-09-30T08:48:07Z")

</div>

> [@djned](#):
>
> The tag contains `/` between the artist and featured artist, but when converting to filename, the / is removed

Thats because the Slash `/` is a non-valid character in the windows file system.  
Like other characters `*` `"` `/` `\` `<` `>` `:` `|` `?` too.  
So you should replace them all if you want to get valid new filenames.

`$replace(x,y,z)` supports multiple parameter pairs y and z.

---

<div class="post-metadata">

### Author: ![LyricsLover](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/l/c6cbf5/32.png) [@LyricsLover](https://community.mp3tag.de/u/LyricsLover)
#### Post date: [September 30, 2025, 8:53am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/6 "2025-09-30T08:53:42Z")

</div>

> [@ohrenkino](#):
>
> Try instead of the plain %artist%:  
> `$replace(%artist%,/, & )`

@djned Please note that this replaces ALL slashes `/` in the ARTIST field with a `&` character.  
If your artist would be called  
`B / I / R / T / H / D / A / Y`  
you get  
`B & I & R & T & H & D & A & Y`

---

<div class="post-metadata">

### Author: ![ohrenkino](https://community.mp3tag.de/user_avatar/community.mp3tag.de/ohrenkino/32/4843_2.png) [@ohrenkino](https://community.mp3tag.de/u/ohrenkino)
#### Post date: [September 30, 2025, 8:55am UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/7 "2025-09-30T08:55:27Z")

</div>

AC/DC becomes AC & DC

---

<div class="post-metadata">

### Author: ![djned](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/b4bc9f/32.png) [@djned](https://community.mp3tag.de/u/djned)
#### Post date: [September 30, 2025, 12:05pm UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/8 "2025-09-30T12:05:53Z")

</div>

Yes, it worked, thank you!

---

<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: [October 30, 2025, 12:06pm UTC](https://community.mp3tag.de/t/replace-the-in-tag-when-converting-to-filename/69901/9 "2025-10-30T12:06:05Z")

</div>

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