UI.getCurrent().navigate doesnt reload page

My App has a common welcome page on “/” for everyone not logged in. After login I redirect to another page with this: UI.getCurrent().navigate(HomeView.class); But the redirect doesnt reload the page correct. If I do the reload myself, there are endless reloads.

You seem to have a never ending loop problem.
Maybe BeforeEnterEvent and rerouteTo will work better? Ensure you test that user is authenticated. If you do not have the code for such a test check the link below.
https://vaadin.com/docs/latest/routing/lifecycle/#rerouting

If you use Spring Security you might already be using something like this, or you might want to use it.
https://vaadin.com/docs/latest/security/enabling-security

@deep-whale the reroute event and rerouteTo solved my problem! Thank you very much! And i am using spring security too, i am just not yet sure wether i use it correct. But i guess it works. thanks again!