I have been wanting to do this for some time now.
You can either do this easy way with Homebrew or take your time to get the code from Github and load it manually.
Install the following cask using Homebrew
brew cask install qlstephen
brew cask install quicklook-json (view json highlighted with colors)
or you can download and load one of the releases from here:
You should load it into the
Restart the Finder –
killall Finder in the Terminal
That is it. You can now view the json files in Mac Finder.