Skip to content
PowerShell Script

PowerShell script – Generate a random password

When working with applications and automation there are many instances where you need to generate a new password. This simple script solves the problem.

This function works with tab for AlphaNumeric or SQLCompliant, this means that you can type the function Get-RandomPassword then add length 32 and press space and then tab through the options.

Get-RandomPassword 32 [Press TAB]

Note that Get-RandomPassword will give you a 64 character password, but if you want to add AlphaNumeric or SQLCompliant you need to specify length first.

Check my repo on GitHub, to get the latest updates in case I create some new options.


Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.