Udemy
    •  
    •  
    •  
    •  
    •  
    •  
    •  
    •  
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
JavaScript Let's Play - Build a Random Card Memory Game 2026
Rating: 4.9 out of 5(47 ratings)
356 students

JavaScript Let's Play - Build a Random Card Memory Game 2026

Enhance your JS skills. Complete course on building a random card memory game, from scratch, using pure JS, HTML and CSS
Created byClyde Matthew
Last updated 1/2026
English

What you'll learn

  • Build a card game using pure JavaScript, HTML, JSON and CSS (no libraries)
  • Use the Fetch API and utilize external JSON data to populate your game
  • Understands fragments, and how to add them to the Document Object Model (DOM)
  • Apply 3D transformations like rotateY() to enhance visual effects in your game
  • Master the Fisher-Yates shuffle algorithm to randomly arrange your game cards
  • Create game mechanics such as card flipping and matching logic
  • Gain a solid understanding of JavaScript, variables, functions, and event handling
  • Use CSS transitions and transformations to provide immediate visual feedback during gameplay, enhancing user engagement
  • Gain proficiency in using the Fetch API to retrieve and manipulate external data, allowing dynamic content in your game
  • Employ randomization techniques, such as shuffling cards, to add unpredictability and excitement to your memory card game
  • Understand array destructuring, ternary operators, decrement operators and more!

Coding Exercises

This course includes our updated coding exercises so you can practice your skills as you learn.

See a demo
Image of coding exercise example

Course content

7 sections61 lectures4h 4m total length
  • Course Intro2:32

    An introduction to this course


  • Section intro1:08

    I have split up this course into sections to make it easy for you to pick up or skip sections that you feel very confident in. To make this work, I'll include the final project code at the end of every section.

    To start things off, I'll also attach the starting files to this lecture (it only contains the images for our cards, nothing else)

  • Course structure and starting code0:22

    I've split this course up into segments, to make it easy for you to skip sections if you so choose


  • Writing the HTML5:20

    In this lecture, I want to set up our HTML for the project. As you'll see, its very easy. All the complicated code will take place in our JavaScript file and CSS file, making the HTML very simple.


  • Writing CSS, and explaining REM vs EM6:44

    When it comes to sizing elements in CSS, two commonly used relative units are em and rem. Both units are essential for creating responsive designs, but they function differently.

  • Using the CSS grid system to display the cards5:03

    When an HTML element's display property is set to grid or inline-grid, it becomes a grid container, and its direct children become grid items. In this lecture we will set up our grid with 6 columns and 2 rows that will ultimately contain our memory cards.

  • Defining CSS root variables4:25

    Defining CSS root variables is an effective way to manage styles across a web project, allowing for easier maintenance and consistency. CSS variables, also known as custom properties, enable developers to store reusable values such as colors, sizes, and fonts.

  • More about CSS :root and naming conventions1:15

    The colon : is a CSS pseudo class selector that you have to use when defining root variables. When declaring CSS variables, it is mandatory to use the -- prefix followed by the variable name. This prefix distinguishes custom properties from standard CSS properties and ensures that the variable is recognized by the browser.

  • Project Files0:11

    Section project files


  • Understanding REM and EM

Requirements

  • A basic understanding of JavaScript, HTML and CSS would be helpful
  • A Mac or PC is required, so you can code alongside with me

Description

*** USE PURE JAVASCRIPT IN 2026 TO CREATE A GAME***

  • Unleash your inner game developer

  • Build a fully functional memory card game, from scratch

  • Understand JSON, Fetch, Fisher-Yates Algo, Animations, 3D Transformations & More

  • Use pure JavaScript, HTML and CSS without libraries or modules

  • Hands-on, interactive course designed for YOU, to take YOU through the entire process of creating a fully functional memory card game from scratch

  • Dive into complex code, made easy

Are you ready for an exhilarating journey into the world of coding as we build a Random Memory Card Game using only pure HTML, CSS, and JavaScript?

WHAT YOU'LL LEARN

  • Build a Game from the Ground Up: Forget libraries and modules! In this hands-on course, you’ll learn to craft every aspect of the game using only HTML, CSS, and JavaScript. By focusing on pure code, you'll gain a deeper understanding of how each component works together to create an engaging user experience.

  • Master Complex Tasks: Coding can be complex, but it doesn’t have to be daunting! I’ll guide you through various methods and techniques for tackling intricate tasks. You’ll become adept at problem-solving and thinking like a developer, giving you the confidence to tackle any coding challenge that comes your way.

  • CSS 3D Transformations: Get ready to dazzle players with stunning visuals! We’ll explore CSS 3D transformations to create an eye-catching flip effect for your cards. You’ll discover the magic of the preserve-3d property, which allows your cards to flip in style, adding depth to your game.

  • Randomization with Fisher-Yates Algorithm: Want to keep players on their toes? Learn how to implement the Fisher-Yates random shuffle algorithm to randomize your card array. This powerful technique not only enhances gameplay but also equips you with skills applicable in various coding scenarios—think gaming, random selections, and more!

  • Understand JSON: Unlock the potential of data handling by exploring JSON (JavaScript Object Notation). You’ll learn how to reference JSON files in your JavaScript code, making it easy to manage game data.

  • Fetch API & Async/Await: Level up your JavaScript skills with the Fetch API! We’ll cover both traditional .then() statements and the modern async/await syntax for seamless data fetching.

  • Track Progress with Counters & Flags: Every great game needs feedback! We’ll implement counters to track player progress and display failure images when matches aren’t made. This will help create a more engaging experience as players strive for success.

  • Celebrate Wins with Confetti: What’s more exciting than winning? We’ll add a delightful winning effect that showers players with confetti when they complete all matches. This fun touch will make your game memorable and encourage players to come back for more!

Random Matching Game Mechanics

Each new game will feature a fresh set of cards, ensuring that no two games are ever the same! You’ll learn how to implement this randomness effectively, keeping gameplay exciting and unpredictable.

* WHAT MAKES THIS COURSE UNIQUE? 

This course is not just about coding; it’s about creating an experience. By the end of our journey, you will have built a fully functional memory card game that showcases your newfound skills. Plus, you'll walk away with valuable knowledge that can be applied across various projects in your development career.

  • Game Logic Implementation: Discover how to implement game mechanics such as card flipping, matching logic, and win/lose conditions. You'll gain practical experience in managing game states and user interactions.

  • Data Handling: Learn how to fetch and utilize external data. You'll work with JSON data to populate your game with unique cards, enhancing your understanding of data structures.

  • User Experience Design: Explore best practices for designing an engaging user interface. You'll implement animations, transitions, and visual feedback to create an immersive gaming experience.

READY TO PLAY? 

Don’t miss out on this opportunity to enhance your coding skills while having fun! Join us in creating something amazing—your very own Random Memory Card Game awaits!

Let’s code something spectacular together!

COURSE HIGHLIGHTS? 

  • Hands-On Project: Each section includes practical exercises where you'll build components of the game step by step, culminating in a fully playable memory card game.

  • Quizzes, Coding Exercises and Tests: I have incorporated tests, quizzes and even coding exercises to get you up to speed, fast.

  • Expert Guidance: Benefit from personalized feedback and mentorship from me, who is passionate about teaching.

I look forward to seeing you in class!

Let's make learning fun—one card at a time!

Clyde

Who this course is for:

  • Anyone who wants to learn how to create a game using JavaScript
  • Any aspiring developer wishing to learn how to work with data and build real web apps
  • Any developer wishing to improve their JavaScript, CSS, HTML and JSON coding skills
  • Anyone who wishes to learn more about web app development
  • A developer who wishes to learn how to truly randomize data that can be used in many applications
  • Anyone who wants to enhance their coding skills