Advertisement

Find your current wallpaper image path in Windows 10

The image you are using as the desktop background can be the one that ships by default with Windows 10, or some image from your personal collection. At Winaero, we have a huge set of themes with very beautiful wallpapers which you can download for free. Your background can also be set by any other app like your web browser or Bing Desktop which downloads images from the Internet. Once you notice an image you like on your Desktop, you might want to find its location on the disk drive so you can save it for further use.

Advertisеment


Here is a script file (*.VBS) which can extract the file path of your current desktop background image from the Registry and show it to you. It is very useful, as the only thing you need is to do is double click the script.

Windows 10 keeps the path to the source image as a binary value in the Registry. When you set an image as your desktop background, it will be converted to match your screen and position preferences like fill, zoom, fit etc. The path to the source image is written in a binary value named TranscodedImageCache at the following Registry key:

HKEY_CURRENT_USER\Control Panel\Desktop

See the following screenshot:Windows 10 TranscodedImageCache

To extract the path of the image from the TranscodedImageCache value, you need to run this script:

Const HKCU = &H80000001 'HKEY_CURRENT_USER

sComputer = "."   

Set oReg=GetObject("winmgmts:{impersonationLevel=impersonate}!\\" _
            & sComputer & "\root\default:StdRegProv")

sKeyPath = "Control Panel\Desktop\"
sValueName = "TranscodedImageCache"
oReg.GetBinaryValue HKCU, sKeyPath, sValueName, sValue


sContents = ""

For i = 24 To UBound(sValue)
  vByte = sValue(i)
  If vByte <> 0 And vByte <> "" Then
    sContents = sContents & Chr(vByte)
  End If
Next

CreateObject("Wscript.Shell").Run "explorer.exe /select,""" & sContents & """"

You can paste this text into Notepad and then save it as a VBS file. Alternatively, you can download the file from here:

Download VBS Script to display your current desktop background location

Extract it to any folder you want and double click it. Immediately the folder containing the wallpaper image will be opened and that image will be selected in File Explorer. This is how it looks in my case:Windows 10 fnd your wallpaper image

That's it.

Support us

Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:

If you like this article, please share it using the buttons below. It won't take a lot from you, but it will help us grow. Thanks for your support!

Advertisеment

Author: Sergey Tkachenko

Sergey Tkachenko is a software developer who started Winaero back in 2011. On this blog, Sergey is writing about everything connected to Microsoft, Windows and popular software. Follow him on Telegram, Twitter, and YouTube.

21 thoughts on “Find your current wallpaper image path in Windows 10”

  1. I would like to use a slightly different form of your program.
    I don’t need to know the location of the wallpaper, so all I need to do is to delete the last line of the program
    and then at this point just display the file name of the current wallpaper without the extension .jpg
    in a small window.
    This allows me to get a description of the current wallpaper by clicking on a shortcut for your program that is on
    the desktop. The file name for each of my wallpaper images is the description for that wallpaper.
    Could you please help me with the code I would need to do this?

  2. If you’re using a slideshow on Windows 10: open Registry Editor via Windows+R, or start>run, and regedit

    Go to location HKEY_CURRENT_USER\SOFTWARE\Classes\Local Settings\Software\Microsoft\Windows\CurrentVersion\AppModel\SystemAppData\

    And search for Slideshow; which should take you to a location like “windows.immersivecontrolpanel_cw5n1h2txyewy\PersistedPickerData\windows.immersivecontrolpanel_cw5n1h2txyewy!microsoft.windows.immersivecontrolpanel\AppBackgroundSlideshow”

    There should be a “LastLocation” key on the right, open it… on the right there is a bunch of what appears to be junk with ….’s and weird characters, but within that is the last folder location of a picture used for the Windows Wallpaper. It’s just broken up a bit.

    Or, is you’re using just a picture, try this location:

    HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Wallpapers

    … and the key “CurrentWallpaperPath” or others

  3. Hi,

    I’d like to set all PCs in a classroom to show one of my wallpapers. Could you modify this code to display PICTURE1.JPG on the selected PC?

    Thanks for the post

    IP

          1. Sorry Sergey, I’m not very good at that. Could you give me a little code to start me off?

            IP

  4. I scoured the internet far and wide for a solution that shows me my current desktop wallpaper. Not one solution worked, regedit or otherwise. Until I found your script, that is -turns out my wallpaper was in a Firefox folder (whyever that is). Thanks so much!

  5. I LOVE the wallpaper finder – I have my wallpaper set in Windows 10 so that it makes a random selection from all the photos on my desktop PC and displays a different image on each of my two monitors for one minute – timing is not synchronized. Problem is, your wonderful magic trick only identifies the wallpaper image on the right hand monitor. Can it be adapted to select either monitor image or otherwise adapted so that either image can be identified? Thank you again, I didn’t dare hope to be able to ID my wallpaper photos and have been spending time scrolling through a lifetime of (chronologically organized) photos (actually including photos of my forebears from the early 20th century) in the hope of finding an elusive image. Great work, thank you again.

    1. I have the same issue as Diana Clark – is there a way to identify the photos on both screens, or choose the screen on which I want the photo identified?

  6. A very welcome addition. I have over 4,000 favourite photographs in my Wallpaper file, collected over my 90 years, that are changed every hour, and now it’s so easy to check when memory fails.
    A shortcut on the desktop made it even easier. THANKS!

  7. Tried the script and it worked exactly as advertised, for the primary monitor.

    Of course if you are using a third-party wallpaper changer like I do ( DMT = Dual Monitor Tools ) the script will point to the generic “DmtWallpaper.bmp” instead of the actual image file from which the wallpaper is generated.

    I have tried many other third-party wallpaper changers ( 15 and counting ) and some will display the actual filename or filename and path, but those programs have other flaws. Sigh. Perhaps some day I will stumble across a program as good as DMT but which also shows the filenames on each of my four monitors.

    The reason I would like that is that I cycle through 19,200 HD wallpapers for my four monitor system, and sometimes I would like to replace one. Do you know how tough it is to find the one image you want out of 19,200 files.

    Thanks anyway ( and another donation is on its way to show my appreciation for Winaero Tweaker ).

Leave a Reply

Your email address will not be published.

css.php
Using Telegram? Subscribe to the blog channel!
Hello. Add your message here.