MacPhun soon to be Skylum have just launched an update to their excellent Luminar software. MacPhun are giving Adobe some sleepless nights recently and are promising to add Digital Asset Management capability in the comming months.
Luminar makes editing intuitive and fun. They offer a number of excellent pre-sets that give a good starting off point before you get to go crazy with any of a huge number of filters.
MacPhun added a Sun ray filter with this release for example that can be used to generate some realistic light rays in a scene. I'm not saying I have done it justice here but you get the idea
MacPhun Luminar 2018 Sun ray example
It's interesting that the filter has identified areas of the photo to cast shadows. The radar on the boat and the cables on Tower Bridge.
Side by side examples
You can alter a number of elements of the rays including number, opacity, warmth, length etc and as a filter you can reduce the effect or mask it out with either a brush or gradient.