diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml
index d7f0daf8b3c7fa47bdef048848f97e368c883d8e..da7e0b9809bb71533cc37a7e0d3439b12f6ccbe8 100644
--- a/.github/workflows/build.yaml
+++ b/.github/workflows/build.yaml
@@ -34,6 +34,9 @@ jobs:
       AUTOBUILD_GITHUB_TOKEN: ${{ secrets.SHARED_AUTOBUILD_GITHUB_TOKEN }}
       AUTOBUILD_INSTALLABLE_CACHE: ${{ github.workspace }}/.autobuild-installables
       AUTOBUILD_VARIABLES_FILE: ${{ github.workspace }}/.build-variables/variables
+      # Direct autobuild to store vcs_url, vcs_branch and vcs_revision in
+      # autobuild-package.xml.
+      AUTOBUILD_VCS_INFO: "true"
       AUTOBUILD_VSVER: "170"
       DEVELOPER_DIR: ${{ matrix.developer_dir }}
       # Ensure that Linden viewer builds engage Bugsplat.
@@ -199,6 +202,11 @@ jobs:
           fi
           export PYTHON_COMMAND_NATIVE="$(native_path "$PYTHON_COMMAND")"
 
+          # branch will be something like "origin/mybranch"
+          branch="$(git branch -r --contains ${{ github.event.pull_request.head.sha || github.sha }} | head -n 1)"
+          # strip off "origin/"
+          export AUTOBUILD_VCS_BRANCH="${branch#*/}"
+
           ./build.sh
 
           # Each artifact is downloaded as a distinct .zip file. Multiple jobs