Skip to main content
All CollectionsAutograders Creating Autograders
Creating Autograders to Check Student Code
Creating Autograders to Check Student Code

Learn what autograders are and how to create them for your own custom assignments with CodeHS Create.

Zach Galant avatar
Written by Zach Galant
Updated over a month ago
Banner: This is a free feature

CodeHS allows teachers to create customized autograders to help grade student work. Most CodeHS coding exercises come with their own pre-written autograder to help guide students and teachers through the curriculum. Read more to find out how autograders work!

CodeHS Autograders

An autograder is a test that runs on a student program to determine whether or not it can be submitted. When a student hits the Submit + Continue button on an assignment, the autograder will run, and if any of the autograder's tests fail, then the student will be prompted to fix their code before submitting (if an assignment doesn't have an autograder, the code will simply be submitted as is).

An autograder with the right error messages can also help the student figure out what is wrong or missing in their code! Students can see if their code passes all the requirements of an autograder by hitting the Check Code button.

An autograder can check for output, as well as if the student used the correct style and/or control structures in their code.

Image of an autograder in an assignment, checking if the assignment has passed all test cases.

Unit Test Test Cases - Similar but Different

The Test Cases in our Unit Test or Practice assignments work a little differently. See General Autograder Test Cases and Unit Tests to learn more about the difference and see Create a Custom Practice Problem to learn more about creating Unit Tests.

Creating an Autograder in the Create App

Autograders are language-specific. With CodeHS Create, you can define autograders to test the content of your student’s code as well as the result that their code produces in any custom exercise that you create. Each language has its own way of creating and defining autograders with code. Once you initialize the Autograder, you will be brought to a code editor with documentation for your chosen language. Read the documentation and our guides carefully, and enjoy the ability to ensure that the code you need to grade is of high quality!

From the Create Assignments Tool

  1. Access the Create Assignments tool by clicking Create from the left menu.

  2. Create a Coding Exercise assignment, save your changes, and close the popup window.

  3. Refresh the Create page, then click the three dots "..." next to the assignment you created and choose Edit.

  4. Scroll down to the bottom of the window and choose Custom Autograder Edit:

A gif demonstrating how to create an autograder following the steps above

From the Create Playlists Tool

If your assignment is in a Playlist, click the three dots "..." next to the assignment name and choose Edit:

Gif demonstrating how to create an autograder for assignments in Playlists.

Language Specific Guides for Autograders

Depending on the chosen coding language, you'll see different options to continue creating an Autograder. See these articles for more information:

Video Demo


For more information, check out Autograders.  

Still have questions? Contact our team at hello@codehs.com to learn more!

Did this answer your question?