Is it possible to install fonts in Windows without admin rights?

5

2

Everytime I try to install fonts in my work Windows 7 machine, I get the error:

"The requested file <font file>.ttf is not a valid font file" 

I'm using reputable fonts sources, like Google Fonts. An example of font is Work Sans.

This informative question, gives the weird solution of turning on the Windows Firewall to install the font. Since I'm not an admin, I can't turn it on.

Due to the uninformative Windows error message, I'd like to know if I can do something, or if I've been wasting my time trying to install a personal font.

neves

Posted 2017-03-06T14:21:10.697

Reputation: 287

Possible duplicate of Using custom fonts without administrator rights?

– phuclv – 2019-01-08T15:04:23.593

Answers

6

Assuming your problem is not being able to install a font without admin rights, below is a solution that does not require admin or additional executables (so will work even with an extremely locked-down computer):

Load a font in Windows using PowerShell

Save the below script as a PowerShell script file somewhere on your machine, next to the TTF and OTF files you want to install:

Add-Type -Name Session -Namespace "" -Member @"
[DllImport("gdi32.dll")]
public static extern int AddFontResource(string filePath);
"@

$null = foreach($font in Get-ChildItem -Recurse -Include *.ttf, *.otf) {
    [Session]::AddFontResource($font.FullName)
}

This script will scan for .ttf and .otf font files in the directory it's running from, and temporarily install them without needing admin access.

The main disadvantage of this is script is that it will only install the font for the duration of your current session. Once you log off or restart your system, you will need to run it again, but that could be automated (depending on how your computer is configured, such as whether it allows running .ps scripts on startup).

Pabru

Posted 2017-03-06T14:21:10.697

Reputation: 915

Thanks for this! While it may not be perfect this is the easiest solution yet without any additional installation. Just set up a task to run at logon and it's done. – Idlehands – 2018-10-01T18:53:26.013

2

I have just stumbled upon a solution, which I have not tried:

  1. Install PortableApps.com Platform
  2. During the installation choose “Select a custom location…” and select a folder that you can modify without admin rights (IMPORTANT STEP)
  3. Create a Fonts folder within PortableApps\PortableApps.com\Data
  4. Copy your font files inside this folder
  5. Close and restart PortableApps
  6. That's it :)

Source: https://woorkup.com/install-fonts-without-administrator-access/

Hope this works for you

mhham

Posted 2017-03-06T14:21:10.697

Reputation: 171

1In general "link only answers" shouldn't be used on SO. You should summarize what is in that article and then reference it only as a source. That way if the link ever changes, then your answer would no longer be complete. – Eric F – 2017-03-06T15:29:20.253

Sorry about that, I'll sum it up in a minute ^^ – mhham – 2017-03-06T15:49:51.540

No problem. Looks good now :) – Eric F – 2017-03-06T17:26:57.873

1

Adding/removing system fonts is an Administrator task because someone could really mess up Windows by deleting or replacing standard system fonts. Unless you are given permissions to have write access in the \Windows\Fonts folder than you will not be able to add fonts.

Pythonic

Posted 2017-03-06T14:21:10.697

Reputation: 309

You cannot install a font without admin, but you can certainly load it for the duration of the session. See my answer for details. – Pabru – 2018-03-21T12:28:55.500