Load you points to the project as described in step 1 of the solution by @Taras.
You can then automatically calculate the length you want without first reprojecting the points - this is done inside the expression with the
geometry ( get_feature_by_id ( @layer, $id )),
geometry ( get_feature_by_id ( @layer, $id+1 ))
You can use this expression e.g. to set a dynamic label. If you want to create a new field, you must first save the layer in antother format (Geopackage, ShapeFile) as QGIS can't edit CSV files. If you reproject the layer during saving (see step 2 in the answer by @Taras), delete the
transform () part of the expression (lines 2, 7 to 9 plus the
, on line 6). If you leave the layer in
EPSG:4326, use the expression exactly as stated above to get length values measured in
When you have the layer as Geopackage, use the expression with field calculator to create the new field.
id + 1 exceeds the last number of a point feature, the result is a
NULL value (no data): that is correct as the last point does not have a next point the measure a length.
Screenshot: as you see, the layer is a csv in
EPSG:4326, the project is in
EPSG:23033. Each point has a label that is dynamically generated by the expression above (plus a
round function to get rid of decimals) that calculates the distance to the next point. The line between the points is also created dynamically with geometry generator, based on the same expression: