> For the complete documentation index, see [llms.txt](https://docs.os.uk/osngd/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.os.uk/osngd/using-os-ngd-data/os-ngd-transport/transport-networks-in-the-os-ngd/rail-network.md).

# Rail network

This page covers the three feature types of the OS rail network: Railway Link, Railway Node and Railway Terminal.

The OS rail network provides a link and node representation of the railways of Great Britain and is structured similarly to the OS road, path and ferry networks. In the OS NGD, the rail network is a separate self-contained network and is not topologically connected to the road, path or ferry networks.&#x20;

## Railway Link, Railway Node and Railway Link Set Feature Types

The [Railway Link](/osngd/data-structure/transport/transport-network/railway-link.md) and [Railway Node](/osngd/data-structure/transport/transport-network/railway-node.md) Feature Types make up the core part of the OS rail network.

* **Railway Links**: These are line features usually representing the centreline of a railway line; they provide information about a railway line, for example, the name, type and operational status of the railway. Each Railway Link will provide a reference to the Railway Nodes at the start and end of the Railway Link in the [Start Node](/osngd/data-structure/transport/transport-network/railway-link.md#startnode) and [End Node](/osngd/data-structure/transport/transport-network/railway-link.md#endnode) attributes, respectively.&#x20;
* **Railway Nodes**: These point features break up the rail network at junctions and places where a Railway Link changes character or name.
* **Railway Link Sets**: A [Railway Link Set feature](/osngd/data-structure/transport/transport-network/railway-link-set.md) is a multi-part link set which represents a collection of Railway Link features that share the same name. The link back to the rail network to tell you which Railway Links the name applies to is represented through the [Railway Link Reference table.](/osngd/data-structure/transport/transport-network/railway-link-set.md#railway-link-reference)

### Links to and from Railway Links, Railway Nodes and Railway Link Sets

The following table describes all the links to and from Railway Links, Railway Nodes and Railway Link Sets within the OS NGD Transport Theme:

| Source Feature Type                                                                                                                       | Foreign Key Attribute | Destination Feature Type                                                          |
| ----------------------------------------------------------------------------------------------------------------------------------------- | --------------------- | --------------------------------------------------------------------------------- |
| [Railway Link](/osngd/data-structure/transport/transport-network/railway-link.md)                                                         | `startnode`           | [Railway Node](/osngd/data-structure/transport/transport-network/railway-node.md) |
| [Railway Link](/osngd/data-structure/transport/transport-network/railway-link.md)                                                         | `endnode`             | [Railway Node](/osngd/data-structure/transport/transport-network/railway-node.md) |
| [Railway Link Set](/osngd/data-structure/transport/transport-network/railway-link-set.md#railway-link-reference) (Railway Link Reference) | `railwaylinkid`       | [Railway Link](/osngd/data-structure/transport/transport-network/railway-link.md) |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.os.uk/osngd/using-os-ngd-data/os-ngd-transport/transport-networks-in-the-os-ngd/rail-network.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
