Microsoft GH-200 Practice Exam Questions & Answers

8 Free Questions Last reviewed December 5, 2026 Prepared & Reviewed by the ValidExamDumps Editorial Team

157 Practice Questions (Our Bank)
120 minutes Exam Duration
Exam Facts

Microsoft GH-200 Exam Details

Key details for this exam, checked against the published exam outline

Exam Code
GH-200
Full Name
GitHub Actions
Issuing Body
Microsoft
Question Format (Our Bank)
Multiple Choice
Delivery
Online proctored through Pearson VUE
Eligibility
Intermediate level experience in GitHub Actions, including workflow creation, automation, and CI/CD pipeline management. Familiarity with CI/CD, GitHub repositories, GitHub Packages, and integrating third-party services is recommended.
Practice Questions

Free GH-200 Practice Questions

Answer each question, then see the correct answer and why it is right

VA
ValidExamDumps Editorial Team Every question and its answer is checked by our GH-200 exam preparation team, who also write the explanation shown with each one. How we research and review these pages

Question 1 Domain 4 Manage GitHub Actions for the enterprise

Which statement correctly explains how labels can be used to direct GitHub Actions workflows to runners?

Correct Answer A
Explanation

Self-hosted runners can carry default labels as well as custom labels. The runs-on field uses these labels to send workflow jobs to runners that satisfy the required conditions. If several labels are listed, a runner must possess all of them before GitHub Actions can allocate the job to it. For that reason, option A is the correct choice. Option B is false, since labels matter most for self-hosted runners. Option C is wrong because GitHub does not need the runner's IP address as a routing label. Option D is also wrong, as workflows select runners through labels or runner groups rather than hostname. This topic tests runner selection, self-hosted runner setup, and workflow job routing.

Question 2 Domain 1 Author and manage workflows

You are a DevOps engineer creating a composite action. One of its steps must run inside a subfolder. Which code snippet should you include in the composite action to set that folder?

Correct Answer D
Explanation

In a composite action, the commands are listed under the runs.steps section of the action metadata file. When a particular command must run from a specific folder, the working-directory key is used, placed on that individual run step. Option D is the right choice because it keeps using: 'composite' under runs and sets working-directory: ${{ inputs.dir }} on the step that executes the script. Option A is wrong because directory is not a valid key for a run step in GitHub Actions. Option B wrongly places directory at the runs level. Option C uses the correct keyword but at the wrong level. This assesses composite action metadata syntax and proper step-level execution settings.

Question 3 Domain 1 Author and manage workflows

As a developer, you must ensure that only actions from trusted sources can be used within your GitHub Enterprise Cloud organization. Which of the statements below are accurate? (Choose three.)

Correct Answer A, B, F
Explanation

Specific actions can be enabled for the organization by identifying them and setting version control, so that only trusted versions are run in workflows.

Verified actions from GitHub can be turned on at the enterprise level, adding a further safeguard by making sure only trusted actions are accessible to workflows.

Actions can be published to an internal marketplace, letting organizations share reusable actions securely within their enterprise without making them public.

Get the complete GH-200 question set

Get Full Access

Question 4 Domain 1 Author and manage workflows

A development team currently runs a PowerShell script on a Linux VM that is set up as a self-hosted runner. The script uses existing tools to compile and package their solution. The team wants to run this script unchanged inside an automated workflow. Which of the following should they do to call their script from a workflow step?

Correct Answer D
Explanation

Because the self-hosted runner runs on a Linux VM and the script is written in PowerShell, the script can be launched with the pwsh (PowerShell Core) shell in a run step of the workflow. This allows the script to execute unchanged on the Linux runner, since PowerShell Core (pwsh) is cross-platform and supports Linux.

Question 5 Domain 3 Author and maintain actions

In which of the following situations would self-hosted runners be necessary in place of GitHub-hosted runners?

Correct Answer A, D
Explanation

GitHub-hosted runners are capped at a certain number of simultaneous workflows (typically 20 on free-tier accounts and 5 on enterprise). When your organization must execute more workflows at the same time, self-hosted runners are needed to raise the amount of available parallel capacity.

Self-hosted runners let you set up specialized hardware or software environments that certain workflows depend on. GitHub-hosted runners might lack access to custom hardware such as GPUs or other specialty resources, which is why self-hosted runners are required in those situations.

Question 6 Domain 2 Consume and troubleshoot workflows

Which menu selections within a repository should you make to access a starter workflow that your organization has made available?

Correct Answer D
Explanation

To use a starter workflow supplied by your organization, open the Actions tab in the repository and choose New workflow. From there you can either build a workflow from scratch or pick from a set of available workflow templates, which include the starter workflows your organization has published.

Question 7 Domain 1 Author and manage workflows

You are a DevOps engineer who must launch a deployment into separate environments, such as development and testing, based on the labels applied to a pull request. The deployment must target the releases branch and should start only when files inside the apps folder are modified. Which code block should be used to set up the trigger for this deployment workflow?

Correct Answer D
Explanation

The trigger needs to rely on the pull_request event because the workflow responds to activity on a pull request. The activity in question is a label being applied, which means types: [labeled] is necessary. The deployment is aimed at the releases branch, so the branch filter should read branches: - 'releases'. The workflow should also execute only when changes occur in files within the apps folder, making paths: - 'apps/**' the proper recursive path filter. Option A is not valid since pull_request_label does not exist as a GitHub Actions event. Option B relies on the incorrect event, pull_request_review. Option C pairs an improper branch and path combination. GitHub workflow syntax allows event activity types, branch filters, and path filters to be combined together.

Question 8 Domain 1 Author and manage workflows

Which run: instruction correctly defines an output for a step?

Correct Answer A
Explanation

GitHub Actions relies on the $GITHUB_OUTPUT file to hand data from one step over to later steps. Appending a key-value pair to that file with echo assigns the output variable (MY_OUTPUT) for the current step.

Study Guide

What the Microsoft GH-200 Exam Covers

Exam domains verified against the Official Microsoft GH-200 exam guide, last checked December 2026.

Domain 1 Author and manage workflows

20% - 25%

Configure workflow triggers for scheduled, manual, webhook, and repository events. Use jobs, steps, conditional logic, and strategy/matrix to generate job variations across OS and runtime versions. Implement YAML anchors and aliases to reuse mappings, and leverage predefined contexts like github, runner, env, and secrets to access workflow metadata and prevent secret leakage in logs.

Above Practice Questions from this Domain: Q2Q3Q4Q7Q8

Domain 2 Consume and troubleshoot workflows

15% - 20%

Identify workflow triggers and diagnose failed runs using logs and run history. Expand YAML anchors and interpret matrix expansions to correlate job names to matrix axes. Locate workflows, artifacts, and logs in the UI and via API, then download and manage artifacts as needed.

Above Practice Question from this Domain: Q6

Domain 3 Author and maintain actions

15% - 20%

Identify and implement action types: JavaScript, Docker, and composite. Specify required files, directory structure, and metadata, then implement workflow commands within actions. Select distribution models (public, private, or marketplace) and apply versioning and release strategies.

Above Practice Question from this Domain: Q5

Domain 4 Manage GitHub Actions for the enterprise

20% - 25%

Define and manage reusable components and templates. Configure and monitor GitHub-hosted and self-hosted runners, apply IP allow lists, manage runner groups, and identify preinstalled software versions. Define and scope encrypted secrets and variables at organization, repository, and environment levels, then access and manage them programmatically via REST APIs.

Above Practice Question from this Domain: Q1

Domain 5 Secure and optimize automation

10% - 15%

Use environment protections and approval gates. Identify trustworthy actions from the Marketplace and mitigate script injection through input sanitization and least-privilege permissions. Pin third-party actions to full commit SHAs, configure granular GITHUB_TOKEN permissions, and use OIDC tokens for cloud provider federation to eliminate long-lived secrets. Generate and verify artifact attestations for deployment verification.

FAQ

GH-200 Exam FAQ

Common questions about the exam itself

What background do I need before taking GH-200?
You need intermediate experience building and managing GitHub Actions workflows, CI/CD pipelines, and automation. Familiarity with GitHub repositories, GitHub Packages, and integrating third-party services helps. This is not an entry-level exam, so hands-on workflow creation experience matters more than theory alone.
How much time do I have to answer the questions on GH-200?
You get 100 minutes to complete the exam. That is testing time only, not the full appointment length. The exam is proctored, so you need a quiet space and a camera.
Is GH-200 harder than GH-900 (GitHub Foundations)?
Yes. GH-900 covers foundational GitHub concepts across the platform. GH-200 is intermediate level and focuses specifically on GitHub Actions, requiring hands-on knowledge of workflow syntax, runners, security, and enterprise-scale management. GH-900 is recommended first if you are new to GitHub.
Which domain in GH-200 gives candidates the most trouble?
Enterprise management and security topics often trip people up because they involve configuring runners at scale, managing secrets programmatically via REST APIs, using OIDC for cloud federation, and enforcing organization-level policies. Real-world lab experience with these features helps more than memorizing alone.
How long should I study for GH-200?
Most candidates need 4 to 6 weeks of focused study if they already write GitHub Actions workflows regularly. If you are new to GitHub Actions, plan for 8 to 12 weeks. The Microsoft Learn study guide is the authoritative source, but hands-on practice building and troubleshooting real workflows is more valuable than reading alone.
How do I take GH-200 and what is exam day like?
You schedule through Pearson VUE for an online proctored exam. You need a quiet, private space, a functioning webcam, and a stable internet connection. The proctor will verify your identity and monitor the session. You cannot reference external materials during the exam.
What happens if I fail GH-200, and can I retake it?
If you fail, you can retake the exam after a waiting period (standard Microsoft policy is 24 hours between attempts). You can schedule a new exam through Pearson VUE. There is no published limit on total attempts, but each exam attempt requires a new seat fee.
How long does the GH-200 certification stay valid?
Microsoft has not published an expiration date for the GitHub Actions certification. Check the official Microsoft Learn certification page for current validity rules, as GitHub certification policies may change.
Which job role is GH-200 best for?
GH-200 is designed for DevOps engineers, software developers, and IT professionals who build and maintain CI/CD pipelines with GitHub Actions. It is especially relevant for teams adopting GitHub Actions at scale or moving to enterprise GitHub deployments.
How does GH-200 fit into the broader GitHub certification track?
GitHub offers a family of certifications: GH-900 (Foundations) is the entry point, GH-200 (Actions) focuses on automation and CI/CD, GH-100 (Enterprise Administrator) covers governance and operations, GH-500 (Advanced Security) addresses supply chain and code security, and GH-300 (Copilot) covers AI-assisted coding. Take them in order or choose based on your role.

Other Microsoft Exams

Free practice questions for more Microsoft certification exams

All Microsoft exams