Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
Ruby on Rails 8: Build a Real-Time Chat & Telegram Features
Rating: 4.8 out of 5(8 ratings)
135 students

Ruby on Rails 8: Build a Real-Time Chat & Telegram Features

Master Rails: Real-Time Chat App with Group Chats, Online Status, Unread Notifications, PostgreSQL + Redis as Fast DB!
Created byTanja Pavlova
Last updated 11/2025
English

What you'll learn

  • Develop a fully functional real-time chat system with Ruby on Rails
  • Integrate Stimulus JS with Rails for smooth and interactive front-end experiences
  • Use Redis not just for pub/sub, but also for efficient storage and retrieval of unread notification data
  • Create and work with various types of associations, including polymorphic relationships, for flexible and reusable data structures
  • Create custom rules and roles for group functionality
  • Build group access protection mechanisms for users who are not members of the group — enforced on both server and client sides
  • Create background jobs to asynchronously broadcast the real-time Turbo Stream updates
  • Use WebSocket lifecycle hooks in Rails Channels to handle real-time online/offline status updates
  • Leverage Active Storage to manage various types of attachments and user avatars
  • Use ActionCable and WebSockets for real-time communication
  • Create a notification system that includes the latest messages and unread notification counts
  • Learn how to use Devise for authentication and customize its controllers to fit a real-time chat app

Course content

12 sections108 lectures6h 36m total length
  • Introduction. What we're going to Build.5:07
  • Before You Begin: Course Scope & Prerequisites2:54

    This introductory lecture explains the scope, structure, and prerequisites of the course.

    You will learn what the course focuses on, why the backend is the main emphasis, and how each section builds on the previous one.

    Please watch this lecture first to ensure you have the required background knowledge and a clear understanding of how to follow the course step by step.

  • Realtime Chat App – Setup Instructions1:18
  • Create a New Rails App with PostgreSQL, TailwindCSS & Devise Gem3:43
  • Create a Home Page with Devise Authentication2:37
  • Pages Structure and Model Associations Overview3:19
  • Create the Contact Model as a Polymorphic Model3:13
  • Create Rooms and Conversants2:07
  • Create Group and GroupUser Models. Set Associations2:49
  • Additional Associations to the User Model: added_users and added_groups1:52
  • Set Redis as the pub/sub server for ActionCable4:06
  • Set Active Storage locally1:50
  • Devise: Login for All Pages Except Home & Set current_user1:11

Requirements

  • Basic knowledges of Ruby on Rails, such as Model-View-Controller (MVC) design pattern, RESTFUL API's requests, basic knowledges of javascript.

Description

Unlock the full potential of Ruby on Rails 8 by building a powerful, real-time chat application inspired by the Telegram Web app.

In this fast-paced, practical course, you'll create private and group chat rooms with features like live messaging, user presence, unread notifications, and file attachments. You'll also manage authentication, user roles, and permissions — all in real time.

We’ll use modern Rails tools and technologies, including:

  • Devise for authentication

  • ActionCable & WebSockets for bi-directional, live communication

  • Redis for real-time unread notification counts as the database and as the Pub/Sub broker for all data updates

  • Stimulus JS for dynamic frontend behavior

  • Active Storage for uploading avatars and sharing files

  • Polymorphic associations and other advanced ActiveRecord patterns

  • Rails Channels and WebSocket lifecycle hooks to track user online/offline status in real time.

You’ll also learn how to:

  • Build real-time group membership and role systems

  • Secure Group Page from Unauthorized Visits on Server and Client Side in Real Time

  • Display last messages and unread message counts — instantly

Throughout the course, we’ll explain complex backend logic using visual diagrams and schemas to make everything clear and digestible.

This course is compact and efficient — just around 6 hours — carefully designed to save your time and deliver only the most relevant, high-impact knowledge. Each lecture builds directly on the last, so it's important to follow in sequence for a smooth learning experience.

Who is this course for?

This course is perfect for Rails developers with basic knowledge of MVC, routing, and RESTful APIs, who want to go beyond CRUD and build something dynamic and production-ready. Familiarity with JavaScript will also help, as we’ll use Stimulus JS for frontend interactions.

If you’ve always wanted to build a real-time app with Rails — this is your blueprint.


F.A.Q

Q: Will I receive support during the course?
A: Due to having over 50,000 students across multiple platforms and a full-time job, the instructor isn’t able to provide one-on-one assistance.

Q: Is this course kept up to date?
A: Absolutely. The course is currently updated and fully compatible with Django 5.0.

Q: Do I get lifetime access after purchasing?
A: Yes. Once you purchase the course, you’ll have lifetime access, and it will remain available on Udemy.

Q: Why are the frontend sections only briefly explained?

A: To keep the course concise and focused, I provide the frontend code with short explanations so you can understand how it connects to the backend logic. The intention is not to deep-dive into frontend frameworks or UI design, but to let you see the complete application flow while keeping the total duration manageable.

Q: Why does this course focus mostly on the backend?

A: This course is intentionally designed to help you master backend development with Ruby on Rails. The goal is to give you a clear, practical understanding of backend concepts such as architecture, models, controllers, and database integration — without spending excessive time on frontend topics.

Who this course is for:

  • Ruby on Rails developers with basic knowledge who want to deepen their core backend skills, better understand database relationships, and master modern real-time application development