Endow a non–profit organization or create (and endow) a religious institution whose core doctrine is uptime of the web site.
You could use a radioactive source maybe to power a raspberry pi? Not sure DNS will still work in 500 years though
Print it to stone (e.g carving) or perhaps to gold. Any museum will have some examples.
I don't even see a way that you could guarantee electrical power supply for 500 years, much less web hosting. Without relying on a power company, solutions like solar panels and windmills only last 30 years or so, with maintenance. Gas and diesel generators are obviously a non-starter.
The closest thing you could get would be drawing up a 500 year contract with a web hosting or media company that you think has a good chance of being around long after you're dead, in a country whose legal system and currency you think has a chance of being around long after you're dead.