Cannot load files when paste URL manually Angular 2 routing?

I solved that problem by adding # to my routes, for example http://localhost:3000/#/profile/1, you can try to do the same. Someone may have better fix for this problem though. Anyway, my solution is adding HashLocationStrategy to AppModule providers:

{ provide: LocationStrategy, useClass: HashLocationStrategy }

Of course, before that, you need to import LocationStrategy and HashLocationStrategy:

import { LocationStrategy, HashLocationStrategy } from '@angular/common';

If you are using RC4 or lower, you add this to your bootstrap method, for example:

bootstrap(
AppComponent,
    [
        { provide: LocationStrategy, useClass: HashLocationStrategy }
    ]);

Thats pretty simple.

When you refresh or manually copy paste URL in address bar, you need to have server side configuration (probably server side routing) to identify and redirect (with PathLocationStrategy) to destination page.

Angular routing is at client side and if you want to do the same with working condition, you need to use HashLocationStrategy