You're previewing the student experience. You don't need to complete this lesson — your progress and XP aren't saved.
Scratch
Beginner
40 mins
Teacher/Student led
+130 XP
Pupils work on their own device

Welcome: Build Your First Scratch Program

Students open Scratch for the first time, follow a short course map, then build and run a simple sequenced program with a sprite, motion, a loop and a backdrop, before saving and reopening the class way.

Teacher Class Feed

Load previous activity

    1 - Start: What We're Building ~4 mins

    Illustration for Start: what we're buildingWhat happens if you give a computer clear steps, in order, and press run?

    Today you start coding in Scratch. In a couple of minutes you will see where this course is heading: games, a website, micro:bit, Python, and one assessed piece of work at the end: a software project with a small team, or a portfolio of your work. Then you will build your first short program step by step at your device: predict what it might do, add the blocks, run it, and fix anything that does not work. You will also save your project where your teacher has told you to keep your work, and open it again to check it is really there.

    2 - What Is Scratch? ~3 mins

    Scratch is a coding website that we can use to create our own games, animations and projects.

    Watch this short minute video to get a quick introduction to it.

    3 - Open the Scratch Website ~3 mins

    Now let's take a look at the Scratch website!

    Open the Scratch website by clicking on the link below. Once it opens up click on the Create link at the top of the page. This will open up the project editor. Once you've done that come back to this tab and move onto the next step.

    scratch.mit.edu


    4 - Remove the Default Sprite ~3 mins

    Every new Scratch project starts with a default sprite, which is a cat. For our project, we want to start with a blank slate, so we will remove this cat sprite.

    To do this, look below the stage area where you see a small thumbnail of the cat sprite. In the corner of this thumbnail, there's a small 'x'. Click on this 'x' to remove the cat sprite from your project.

    Don't worry about losing the cat sprite. If you ever want it back, you can always find it in the sprite library!


    5 - Add a Sprite to Your Project ~2 mins

    Scratch comes with a sprite library that's packed full of different characters.

    Open up the sprite library and add the Bat sprite to your project.

    You'll see that it gets added into the stage area and we can now give it some code!


    6 - Make the Sprite Move ~5 mins

    Now let's try making the sprite move. Add the following code blocks to the code area by dragging and dropping them. The colour of the blocks lets you know which "block category" to open.

    when green flag clicked move (10) steps turn cw (15) degrees

    You'll notice that they click in and join together when you drop them close to each other. Don't worry if it takes a few attempts to drag and drop them in. You'll get used to adding the code blocks in no time at all.
    Once you've added these blocks click the green flag at the top left of the stage area to 'run' the code. Each time you click the green flag it will run the code and your sprite will move a small bit and turn.


    7 - Change the Values Inside the Blocks ~3 mins

    You may have noticed the numbers inside the blocks you added. The blocks use these numbers to decide how much to move or to turn.

    Change the numbers like below:

    when green flag clicked move (10) steps // change the 10 to 50 turn cw (15) degrees // change the 15 to 25

    Now try clicking the green flag again. You will notice that the sprite moves and turns even more now.


    8 - Create a Loop ~5 mins

    A loop is something that makes a set of instructions "loop" or repeat a number of times.

    We're going to add a loop to our code by doing the following:

    1. Break off the two motion blocks from the "when green flag clicked" block.
    2. Drag in a "forever" block from the Control toolbox. You'll notice that this block has a different shape to it.
    3. Drag the 2 motion blocks inside the "forever" block.

    when green flag clicked forever move (50) steps turn cw (25) degrees end

    Now click on the green flag and your sprite should keep moving around in a circle! This is because we are forever repeating the move and turn instructions.


    9 - Add a Backdrop ~2 mins

    As well as a sprite library, Scratch also has a backdrop library.

    Backdrops are images that appear in the background of your stage area. They're great for setting the scene and making your game or animation look better!

    Add a backdrop to your project by choosing one from the backdrop library.


    10 - Discover More with Scratch ~2 mins

    Your first Scratch program works. Now find out what else the blocks can do.

    Pick one block you have not used yet and add it to your sprite. Good places to look:

    • Looks - change the sprite's size, colour, or make it say something
    • Sound - play a sound when the program runs
    • Control - add a wait so the movement slows down

    Run it, and be ready to say what changed. If it does something you did not expect, pull the new block back out and run it again to check that was the cause. That is debugging, and you will do it in every lesson from here.

    11 - Make Sense: What Worked, What Broke ~3 mins

    Together, look back at what you built:

    • What worked the first time you clicked the green flag?
    • What did not work? What exactly did the sprite do instead?
    • How did you find the problem, and what change fixed it?
    • If you made a prediction at the start, how close was it to what actually happened?

    Nobody gets a program right first time. Being able to say what went wrong, and what you changed, is the skill.

    12 - Reflect ~2 mins

    Think about and discuss:

    • A computer does exactly what you tell it, in the order you tell it. Nothing you built today worked anything out for itself. Where does that make life easier, and where does it make it harder?
    • What is one thing you would like to be able to make by the end of this course?

    13 - What You Covered ~3 mins

    Today you:

    • Saw where this course is heading, and that it ends with one assessed piece of work: a team software project or a portfolio of your work
    • Opened Scratch, added a sprite, and built a short sequence with motion and a loop
    • Ran the program, changed values, added a backdrop, and fixed what did not work
    • Started to explore other block categories

    Save your project now, using the save routine your teacher put up at the start of the lesson. Then close it and open it again, so you know for certain it is really there next lesson. You will save this way in every lesson from now on.

    End of lesson
    123learn · Sample lesson

    That was a sample lesson from Junior Cycle Coding Short Course

    Every lesson in the course is ready to teach like this one. See what else comes with it, and how to order it.

    Copyright Notice
    This lesson is copyright of Coding Ireland 2017 - 2026. Unauthorised use, copying or distribution is not allowed.

    Scratch is developed by the Lifelong Kindergarten Group at the MIT Media Lab. It is available for free at https://scratch.mit.edu
    🍪 Our website uses cookies to make your browsing experience better. By using our website you agree to our use of cookies. Learn more