# Trim spaces before Artist

**URL:** https://community.mp3tag.de/t/trim-spaces-before-artist/67833
**Category:** Mac
**Created:** [March 15, 2025, 12:16pm UTC](https://community.mp3tag.de/t/trim-spaces-before-artist/67833 "2025-03-15T12:16:57Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![DJDeek215](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/97f17d/32.png) [@DJDeek215](https://community.mp3tag.de/u/DJDeek215)
#### Post date: [March 15, 2025, 12:16pm UTC](https://community.mp3tag.de/t/trim-spaces-before-artist/67833/1 "2025-03-15T12:16:57Z")

</div>

Hello. I'm very new to MP3Tag. It's been very helpful so far. I download many songs from different DJ Pools. One particular pool, inserts unwanted spaces before the Artist's name. That space can offset when searching for artist while I'm actively DJing. For Example [Taylor Swift] when it should be [Taylor Swift]. I've used the following & I'm stuck: Field\_ARTIST &  
Formatstring $trim(%_artist%). Should I make the underscore "_" an actual space? I appreciate any & all help. Thank You all

---

<div class="post-metadata">

### Author: ![DJDeek215](https://community.mp3tag.de/letter_avatar_proxy/v4/letter/d/97f17d/32.png) [@DJDeek215](https://community.mp3tag.de/u/DJDeek215)
#### Post date: [March 15, 2025, 1:19pm UTC](https://community.mp3tag.de/t/trim-spaces-before-artist/67833/2 "2025-03-15T13:19:54Z")

</div>

I am happy to share, that after much trial & error...I have figured it out. Thankfully!

---

<div class="post-metadata">

### Author: ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)
#### Post date: [March 16, 2025, 2:11pm UTC](https://community.mp3tag.de/t/trim-spaces-before-artist/67833/3 "2025-03-16T14:11:53Z")

</div>

Glad you found a solution! In fact, your approach from the initial post already looked correct -- one way would be to use **Convert \> Tag - Tag** for field `ARTIST` using

`$trim(%artist%)`

as format string. The same is possible as action of type **Format tag field**.

---

<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: [April 15, 2025, 2:12pm UTC](https://community.mp3tag.de/t/trim-spaces-before-artist/67833/4 "2025-04-15T14:12:20Z")

</div>

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