This guide walks you through creating a free Supabase project, setting up the required database tables, wiring in your credentials, and serving kChat locally so you can start chatting straight away. No prior Supabase experience is needed, and you will not need to install Node.js, a bundler, or any other tooling — just a text editor and a way to serve static files.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/korynthian/chatroom/llms.txt
Use this file to discover all available pages before exploring further.
Create a Supabase Project
- Go to supabase.com and sign up for a free account (or sign in if you already have one).
- Click New project, give it a name, choose a region close to you, and set a database password. Wait about a minute for the project to provision.
- Once the project is ready, open Project Settings → API. Note down two values — you will need them in a later step:
- Project URL (looks like
https://<your-project-ref>.supabase.co) - Publishable API key (listed under Project API keys as
anon / public)
- Project URL (looks like
Create the Database Tables
In your Supabase project, open the SQL Editor (left sidebar) and run the following schema. This creates the three tables kChat depends on: Click Run to execute the SQL. You should see a success message for each statement.
rooms, messages, and profiles.Create a Room
kChat’s index page lists whatever rows exist in the You can add as many rooms as you like by repeating the insert with different names.
rooms table. Insert at least one room so you have something to chat in. Still in the SQL Editor, run:Configure kChat
Clone or download the kChat repository, then open both Make the same change in both files —
chat.js and indextablenames.js in your editor. At the top of each file you will find the three lines that initialise the Supabase client. Replace the placeholder URL and key with the values you copied in Step 1:chat.js powers the chatroom page and indextablenames.js powers the room-list page, and each file initialises its own client.Serve the Files
kChat is a static site, so any HTTP server will work. You cannot simply double-click Run either command from the root of the kChat directory (the folder that contains
index.html in a file browser because some browsers block local fetch requests made from file:// URLs; use a proper server instead.index.html).Open kChat
Navigate to http://localhost:8080 in your browser.
- On your first visit you will be prompted to enter a username. Type anything you like — it is saved to
localStorageand reused automatically in future sessions. - The index page will display the room (or rooms) you inserted in Step 3. Click a room name to open it.
- Type a message in the text input and press Enter to send it. New messages from other users appear automatically within one second.