How Do You Actually Utilize the .plexmatch File?

Version#: 1.25.9+ (this was available from then on)

There’s this article (https://support.plex.tv/articles/plexmatch/), but I still can’t get the .plexmatch file to do anything really useful. It states “Match hint information provided in a ‘.plexmatch’ file overrides the directory and filenames, allowing greater control over matching without requiring you to rename your existing files”

So, say I’m trying to match The Witcher. And just for this example, I have a very-badly-named folder structure for season 1, episode 1 as:

Netflix’s The Witcher/S1/1_The.Ends.Beginning.mkv

This is obviously not how Plex wants the naming scheme (and it’s not how I have it, this is just for the example), but it states in the article that it doesn’t require renaming the files. So, I create a .plexmatch file with this in the main folder:

title: The Witcher
year: 2019
tvdbid: 362696

Except it doesn’t change anything. It still can’t find The Witcher. I guess, what exactly needs to be done to match without renaming the files to Plex’s naming scheme? This seemed like the best thing I’ve found, but it hasn’t worked once when testing. I’ve tried throwing the episodes in there based on the article, having a .plexmatch file in both the show directory and season directory, and everything else. Still nothing.

Also, what is the “guid” referenced in the article? It says “guid sets a Plex URI-style media identification GUID, in the format [source]://[id]”, but I’m not sure what that means exactly.

The reason for doing all this is there are some shows that don’t do well with the Plex dance. My Top Gear folder ends up split into multiple shows that I need to re-merge together. It would be awesome to have something that forces it all together immediately. Please don’t tell me to just rename the file the way Plex wants, the whole purpose of this is to figure out how to properly implement the .plexmatch file only.

What agents are you using?

The new agents use a different format
https://support.plex.tv/articles/naming-and-organizing-your-movie-media-files/

/Movies
   /Batman Begins (2005) {imdb-tt0372784}
      Batman Begins (2005) {imdb-tt0372784}.mp4

You can also use that format in the main show folder for TV shows
https://support.plex.tv/articles/naming-and-organizing-your-tv-show-files/

This is using the Plex TV Series Agent. PlexMatch was just recently updated in version 1.30.0.6359.

This is to further force a match, but it has never worked for me. Putting {tvdb-#######} hasn’t worked either. This is about the .plexmatch file from the article. Obviously the format I posted is incorrect, as I stated, to see how to properly use .plexmatch files to force a correct match with the incorrect naming scheme shown.

Make sure both Agent and Scanner is set to Plex TV Series

image

Also do a Refresh All Metadata

image

Then report back

I did all of that. I still end up with things like this (The Firefly entry is actually Top Gear episodes)…

Plex Top Gear

I have {tvdb-74608} in the Top Gear folder name and a .plexmatch file with the following contents within that folder…

tvdbid: 74608
title: Top Gear
year: 2002

Putting the ID in the folder name and the .plexmatch file in the folder doesn’t seem to do anything at all. Even though, according to that article I listed in the first post, the .plexmatch should override the directory name anyway.

And I still don’t understand what the guid hint does for .plexmatch. For Top Gear, it looks like it should be…

guid: plex://show/2F5d9c07fd02391c001f57e02f

Or would it be…

guid: plex://show/top-gear

Because the article doesn’t explain that hint at all really.

You’re on the right track, but because of your episode filenames, the episodes are not being matched. You need to add the episode hints too.

i.e.

Netflix’s The Witcher/S1/1_The.Ends.Beginning.mkv

Add the .plexmatch file in this S1 folder alongside the episodes.

title: The Witcher
year: 2019
tvdbid: 362696
Season: 2
ep: 1: 1_The.Ends.Beginning.mkv

Add the other episodes into this file. Create a similar .plexmatch file for other seasons.

Edit: On further thought, it might just be you are missing the season hint. For episode, we may be able to parse out the “1” for the episode number so it’s just the season info missing. Try with just the season hint and if that doesn’t work, add the episode hints.

1 Like

Hmmm, so I got it to work for that test file for The Witcher. I also made another test file with some really messed up naming for Top Gear (just to see how well it would work) and got it to work too!

But I have a TV Show called Dead Set that won’t show up at all. The info in the Season 1 folder for that show is…

title: Dead Set
year: 2008
tvdbid: 83427
season: 1
ep: 1: S01E01 - Outbreak/Episode1name.mkv
ep: 2: S01E02 - Can the Housemates Keep Angel Alive_/Episode2name.mkv
ep: 3: S01E03 - Live Feed/Episode3name.mkv
ep: 4: S01E04 - Running/Episode4name.mkv
ep: 5: S01E05 - A Way Out/Episode5name.mkv

For reference, the filepath for episode 1 is “TV Shows\Dead Set (2008)\Season 01 (2008)\S01E01 - Outbreak\file”. I’ve had issues with this particular show in the past. Plex really doesn’t like it. Did the full dance and all after putting in its .plexmatch file.

My guess is the “/” in the filename.

But if I use The Witcher example from earlier and throw that episode into a folder and have the .plexmatch info as follows, it works with the “/”…

title: The Witcher
year: 2019
tvdbid: 362696
season: 1
ep: 1: S01E01 - The End’s Beginning/1_The.Ends.Beginning.mkv

It’s just this one TV Show that appears to never want to work like the rest.

Can you show me the actual filenames for the one that doesn’t work?

Well, I figured out what’s wrong, but it seems like a really odd thing. I rip almost all my own movies/shows so their filenames have a specific format. For Dead Set episode 1 it’s…

Dead.Set.S01E01.Outbreak.2008.480p.DVDRip.x264.DD.2.0-MyCollection-NeedsUpdate.mkv

I got this show so long ago on DVD when I didn’t have much hard drive space, so they are only in 480p. So at the end, instead of just “-MyCollection.mkv” I had “-MyCollection-NeedsUpdate.mkv” to designate that I need to buy a better quality bluray someday and re-rip when I have time.

Apparently, it’s that second dash in the filename that kicks it out. If I remove the dash so it’s “-MyCollectionNeedsUpdate.mkv” it works! Looks like it can only handle a single dash in the filename, which is odd, but at least I finally figured out why this particular show has given me so many problems in Plex.

EDIT: Sorry, that was supposed to be DVDRip not DVD-Rip in the filename. It’s updated now.

I’m guessing this is due to the normal Plex naming convention of “S01E01 - Name of Episode - Optional Info.ext” where it is set up to disregard everything after the second dash and that was causing the filenames to not match.

I checked and the dashes shouldn’t matter. Can you provide me the full path and filenames so I can try to reproduce?

Edit - I tried Dead.set\S1\Dead.Set.S01E01.Outbreak.2008.480p.DVDRip.x264.DD.2.0-MyCollection-NeedsUpdate.mkv and that matched perfectly for me without needing the .plexmatch file.

Not sure what to say, because now I can’t get the show to go away lol. I added the dash back in and it’s sticking around now. Here’s the filepath (the library points to the TV Shows folder)…

Maybe something got caught up somewhere and eventually worked out with all the changes I was making and it was something else. Well, they are all there now and working fine for me. Thanks!


One other weird thing I noticed though while routing around in my shows and movies (since this all got me looking at things closer) is that I was missing a couple of episodes and movies here and there in Plex, and I realized they all had the same thing in common. Their filenames all ended in “-Video” before the extension. I use “-Video”, “-Audio”, “-Subtitles”, etc on the end of files sometimes to denote that I should re-rip those specific parts if I notice issues when playing back. My computer isn’t the best, so it sometimes hiccups when ripping.

I changed all those to “-Vid” and they all showed up in Plex. I added “-Video” onto a random filename and it immediately was removed from Plex. Is this a specific keyword designed to denote the difference between an “Other Video” file and a video file in “Movies” or “TV Shows”?

Since this issue was easily re-creatable on my end, I can give better specifics. Take something like “Filename.mkv” and change it to “Filename-Video.mkv”. Plex removes it from the library. Delete any 1 letter from that Video word, like “Filename-Vide.mkv” and it comes back.

Thanks. I can confirm that having “-video” at the end does make it so the file is not scanned. That is meant to be used to identify music videos for a music library. I will get this filed as a bug.

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