# node-opcua
The most complete OPC UA stack for Node.js and the browser, written in TypeScript.
[](https://www.npmjs.com/package/node-opcua)
[](https://github.com/node-opcua/node-opcua/actions/workflows/workflow.yml)
[](https://coveralls.io/r/node-opcua/node-opcua)
[](https://lernajs.io/)
[](https://leanpub.com/node-opcuabyexample-edition2024)
[](https://www.npmtrends.com/node-opcua-server)
[](https://www.npmtrends.com/node-opcua-server)
[](https://www.npmtrends.com/node-opcua-client)
[](https://www.npmtrends.com/node-opcua-client)
---
## Why node-opcua?
- **Full OPC UA stack** — Client, Server, Discovery, and Aggregation in a single toolkit
- **Security first** — Supports all OPC UA security policies, encrypted communication, and certificate management out of the box
- **Cross-platform** — Runs on Windows, Linux, macOS, and in the browser
- **Modular architecture** — Use only the packages you need, from a lightweight client to a full-featured server
- **Battle-tested** — Trusted in production by industrial companies worldwide
- **Well documented** — Comprehensive book, API reference, tutorials, and guided examples
## Quick Start
### Install node-opcua as an npm package
```shell
$ mkdir myproject
$ cd myproject
$ npm init
$ npm install node-opcua
```
### Try the sample server & client
```shell
$ npm install node-opcua-samples
$ ./node_modules/.bin/simple_server
```
```shell
$ ./node_modules/.bin/simple_client -e "opc.tcp://opcuademo.sterfive.com:26543"
```
## Node.js Requirement
- **Node.js 22.13** or above is required.
## Documentation
[](https://leanpub.com/node-opcuabyexample-edition2024)
**[NodeOPCUA by Example](https://leanpub.com/node-opcuabyexample-edition2024)** — The best starting point. Dozens of practical, ready-to-use, and fully documented examples.
### Tutorials
- [Create a Server](https://github.com/node-opcua/node-opcua/blob/master/documentation/creating_a_server.md)
- [Create a Client in TypeScript](https://github.com/node-opcua/node-opcua/blob/master/documentation/creating_a_client_typescript.md)
- [Role-Based Security & User Management (OPC 10000-18)](https://github.com/node-opcua/node-opcua/blob/master/documentation/role_based_security.md)
- [Reverse Connect (OPC 10000-6 §7.1.3)](https://github.com/node-opcua/node-opcua/blob/master/documentation/reverse_connect.md)
- More advanced examples and training material are available for [NodeOPCUA Subscription members](https://support.sterfive.com)
### API Reference
- [API Documentation](https://node-opcua.github.io/api_doc/index.html)
#### API surface
The supported, semver-protected API is what the generated documentation
above describes. Symbols tagged `@internal` in the source (secure-channel
plumbing such as `MessageBuilder`, `ClientSecureChannelLayer`,
`ServerSecureChannelLayer`, and `OPCUAServerEndPoint` construction options)
are node-opcua internals: they are reachable through re-exports for
historical reasons, but they may change in a minor release. Applications
configure security and keys exclusively through `OPCUAClient`,
`OPCUAServer`, and `OPCUACertificateManager` options.
---
## 🏢 Professional Support
Need help with your OPC UA project? Sterfive offers professional support and consulting for node-opcua.
| | **Community** (GitHub) | **Professional** (Sterfive) |
|---------------------------|:------------------------:|:--------------------------:|
| GitHub Issues | ✅ | ✅ |
| CVE security advisories | After disclosure | **Early access — patch before public disclosure** |
| Private support channel | — | ✅ |
| Extended documentation | — | ✅ |
| Guaranteed response time | — | ✅ |
| Consulting & training | — | ✅ |
| Certifiable builds | — | ✅ |
[](https://support.sterfive.com)
📧 Contact: [contact@sterfive.com](mailto:contact@sterfive.com) · 🌐 [sterfive.com](https://www.sterfive.com)
---
## Ecosystem
### AI-Powered Modeling with MCP
**[node-opcua-modeler-mcp-server](https://www.npmjs.com/package/node-opcua-modeler-mcp-server)** — An [MCP server](https://modelcontextprotocol.io) that gives AI agents access to the OPC UA companion specification type system. Discover types, resolve namespace dependencies, and look up engineering units — all from your AI coding assistant.
```bash
npx node-opcua-modeler-mcp-server
```
### OPC UA Modeler
**[OPC UA Modeler](https://github.com/node-opcua/opcua-modeler)** — Designing an information model? Write it in YAML, get standard NodeSet2.xml: create, validate, and generate OPC UA information models with full companion spec support, then load the result with `nodeset_filename`.
- [Open specification, JSON Schema and example models](https://github.com/node-opcua/opcua-modeler) on GitHub
- [Online NodeSet2 editor](https://opcua-modeler.sterfive.io) — nothing to install
- [Documentation](https://opcua-modeler.doc.sterfive.com/), starting with [How to create a NodeSet2.xml file](https://opcua-modeler.doc.sterfive.com/docs/guides/create-nodeset2-xml)
## Supported Features
node-opcua implements a comprehensive set of OPC UA services, transport protocols, security policies, and server/client profiles.
👉 **[View the full supported features matrix](./supported_features.md)**
---
## Roadmap
- Improved documentation and more tutorials
- Compliance testing and certification (CTT)
- Support for redundancy
- Session-less transactions
- JTokens and OAuth
Want to influence the roadmap? [Contact Sterfive](mailto:contact@sterfive.com).
---
## :heart: Sponsors
node-opcua is funded entirely by its users. If you use node-opcua in your project, please consider supporting its continued development:
- 🌟 [**Become a sponsor on GitHub**](https://github.com/sponsors/node-opcua)
Your sponsorship ensures long-term maintenance, new features, bug fixes, and representation of the node-opcua community at the OPC Foundation.
---
## Contributors
This project exists thanks to all the people who contribute.
<a href = "https://github.com/node-opcua/node-opcua/graphs/contributors">
<img src = "https://contrib.rocks/image?repo=node-opcua/node-opcua"/>
</a>
## Contributing
We welcome contributions! Here's how to get started with the source:
```shell
$ git clone git://github.com/node-opcua/node-opcua.git
$ cd node-opcua
$ npm install -g pnpm
$ pnpm install
$ pnpm recursive install
$ pnpm build
```
### Running the demo server from source
```shell
$ node packages/node-opcua-samples/bin/simple_server
```
### Running the demo client from source
```shell
$ node packages/node-opcua-samples/bin/simple_client.js -e "opc.tcp://opcuademo.sterfive.com:26543"
```
---
## License
node-opcua is [MIT licensed](./LICENSE).
- You can freely use it in open-source and commercial applications.
- You must include the copyright notice in all copies or substantial portions of the software.
- node-opcua comes without any warranty of any kind.
You are strongly encouraged to join the [NodeOPCUA Membership](https://support.sterfive.com) for additional benefits and support.
## Copyright
Copyright © 2014-2026 Sterfive SAS — 833264583 RCS ORLEANS — France ([sterfive.com](https://www.sterfive.com))