--- title: createSession hidden: true --- # createSession [MODES: framework, data, declarative] ## Summary [Reference Documentation ↗](https://api.reactrouter.com/v7/functions/react-router.createSession.html) Creates a new Session object. Note: This function is typically not invoked directly by application code. Instead, use a `SessionStorage` object's `getSession` method.