Link Search Menu Expand Document
Start for Free


This page discusses using .NET to interact with Stardog.

Page Contents
  1. Overview
  2. Examples
  3. dotNetRDF
  4. Trinity RDF


In the HTTP API section, we looked at how to interact with Stardog over a network via HTTP.

The HTTP API can be used from .NET applications but there are third-party libraries that provide a more convenient way to work with Stardog.


The examples hosted in our Stardog examples repository show how to use .NET to connect to a Stardog server, manage Stardog databases and query them. They also show some basic examples of using dotNetRDF and Trinity RDF discussed below.


The open source dotNetRDF library provides functionality to parse, manage, query and write RDF graphs along with a custom Stardog connector. See the documentation for using dotNetRDF with Stardog.

dotNetRDF is an open source library developed and supported by third parties; questions or issues with the .NET API should be directed to

You should also be aware that dotNetRDF uses the HTTP API for all communication with Stardog so you must enable the HTTP server to use Stardog from .NET. It’s enabled by default so most users should not need to do anything to fulfill this requirement.

Trinity RDF

Another possibility for using Stardog within .NET applications is the Trinity RDF library which provides an Object Mapping layer for RDF graphs. Trinity RDF lets users map RDF/OWL terms to .NET objects and uses byte-code manipulation at compilation time to generate efficient programs. See the Trinity RDF documentation for more details about using Trinity RDF.