Is this possible with javascript? (language switch)

I want it to be possible to switch between german and english by the click of a button. Is this possible to do with JS or do I have to go back-end and mess around?

You can do it, but you’re going to need some back-end support somehow that generates the content in both German and English.

The easy (but network-intensive way) would be to generate the content in both German and English at the same time, hiding the not wanted language by default, then using javascript to hide the default and show the alternate language.