Certain datasets provided by Trafikkontoret are fairly large and can introduce certain issues with QGIS.

The main issue is adding WFS layers as it requires one to download the dataset before QGIS can start working with it.

QGIS has an internal timeout for network requests which even if the service does provide the data, may interrupt it before it completes.
For example the "NVDB - Funktionell vägklass" dataset is likely to introduce this problem.

To prevent these problems from occuring one can increase the timeout to prevent QGIS from interrupting the request.

In order to do this follow these steps:

1) Enter the "Settings" menu ("Inställningar") and choose "Options" ("Alternativ").

2) Enter the "Network" tab ("Nätverk").
3) Locate the "Timeout for network requests (ms)" ("Tidsbegränsning på nätverksförfrågan (ms)") in the "General" ("Allmänt") section.

4) Enter a number greater than the already existing one. The number represents milliseconds before timeout and it may need a few minutes for some datasets.
5) Press OK to save.

You should now be able to utilize larger datasets without experiencing timeouts when adding the layers.

Even with this change, some datasets may still be too large to retrieve. In these cases it is usually easiest to separately download the dataset as a shapefile using a web browser and load this into QGIS.
You can download a dataset by adding &outputFormat=SHAPE-ZIP to the end of the request.
For example:

https://openstreetgs.stockholm.se/geoservice/api//wfs?SERVICE=WFS&VERSION=1.0.0
&request=GetFeature&TYPENAME=LAYER_NAME&outputFormat=SHAPE-ZIP

Another issue with QGIS when using large datasets is its rendering process. Whenever the map is panned, QGIS calls a re-rendering of the map.
If the dataset is large and possibly use advanced thematises it can take some time for this rendering proccess to complete.
If one has issues with the rendering times one can do a few things to improve the experience.

First one can introduce multi-threaded rendering. Clients with multi-core processors should experience a slight boost from activating this option.
However, this only helps if multiple layers are present in which case QGIS will render each layer individually on separate threads.

To activate this option follow these steps:
1) Enter the "Settings" menu ("Inställningar") and choose "Options" ("Alternativ").

2) Enter the "Rendering" tab ("Rendering").
3) Locate and check the "Render layers in parallel by using many CPU cores" option ("Rendera lager parallellt genom att använda flera processorkärnor") in the "Rendering behaviour" ("Renderingsuppträdande") section.

4) Press OK to save.

QGIS will now whenever possible use more system resources to render the layers faster.


If one wants to pan the map but does not require a re-render one can also quickly disable the rendering all together by unchecking the "Render" ("Rendera") option in the lower right corner of QGIS.

This mean QGIS will not re-render the map at all even if the map is panned. However, this also makes QGIS not render new sections of the map until the option is rechecked.