{"id":73374,"date":"2026-11-23T10:00:44","date_gmt":"2026-11-23T18:00:44","guid":{"rendered":"https:\/\/devblogs.microsoft.com\/devops\/?p=73374"},"modified":"2026-11-23T02:18:32","modified_gmt":"2026-11-23T10:18:32","slug":"new-guidance-to-optimize-git-performance-in-azure-repos","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/devops\/new-guidance-to-optimize-git-performance-in-azure-repos\/","title":{"rendered":"New guidance to optimize Git performance in Azure Repos"},"content":{"rendered":"<p>Git works well for most development workflows. But a change that seems harmless can make a repository harder to work with. Here are a few examples of how that can happen.<\/p>\n<h2>Committing binaries directly to your repository<\/h2>\n<p>Binaries are more likely than source code files to differ a lot between versions, so delta compression is less effective. This makes the repository grow faster.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth.webp\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth-1024x384.webp\" alt=\"Diagram showing a one-line source edit adding a 20 MB binary delta and growing a Git repository from 100 MB to 120 MB.\" width=\"1024\" height=\"384\" class=\"aligncenter size-large wp-image-73750\" srcset=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth-1024x384.webp 1024w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth-300x113.webp 300w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth-768x288.webp 768w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth-1536x576.webp 1536w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-binary-growth.webp 1920w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/p>\n<h2>Reordering generated content<\/h2>\n<p>If you use generated text that adds or removes a small amount of data with each change, but the data isn&#8217;t ordered consistently, Git then ends up storing extra data for what would otherwise be a small update.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering.webp\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering-1024x384.webp\" alt=\"Git diff comparison: stable ordering shows one removed and one added line; reordered keys show five removed and five added lines.\" width=\"1024\" height=\"384\" class=\"aligncenter size-large wp-image-73736\" srcset=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering-1024x384.webp 1024w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering-300x113.webp 300w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering-768x288.webp 768w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering-1536x576.webp 1536w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-generated-file-ordering.webp 1920w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/p>\n<h2>Downloading more data than you need<\/h2>\n<p>By default, <code>git clone &lt;repo-url&gt;<\/code> downloads data for all branches on the remote. A large file pushed to one developer&#8217;s branch can therefore slow down cloning for others, even if that branch is never merged into <code>main<\/code>.<\/p>\n<p><a href=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison.webp\"><img decoding=\"async\" src=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison-1024x384.webp\" alt=\"Diagram comparing a 104 MB standard Git clone with a 1 MB single-branch clone of main when another branch contains a large file.\" width=\"1024\" height=\"384\" class=\"aligncenter size-large wp-image-73735\" srcset=\"https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison-1024x384.webp 1024w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison-300x113.webp 300w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison-768x288.webp 768w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison-1536x576.webp 1536w, https:\/\/devblogs.microsoft.com\/devops\/wp-content\/uploads\/sites\/6\/2026\/09\/repo-optimization-clone-branch-comparison.webp 1920w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/p>\n<p>To help you understand and address issues like these, we&#8217;ve published new guidance for Azure Repos: <a href=\"https:\/\/learn.microsoft.com\/en-us\/azure\/devops\/repos\/git\/optimize-repository-performance?view=azure-devops\">Optimize repository performance<\/a>.<\/p>\n<p>The guide walks you through checking repository health, finding what&#8217;s contributing to growth, and reducing the data transferred during clones and fetches.<\/p>\n<p>Let us know in the comments what repository performance challenges you&#8217;ve run into and how you solved them.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Git works well for most development workflows. But a change that seems harmless can make a repository harder to work with. Here are a few examples of how that can happen. Committing binaries directly to your repository Binaries are more likely than source code files to differ a lot between versions, so delta compression is [&hellip;]<\/p>\n","protected":false},"author":203892,"featured_media":73428,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[225],"tags":[],"class_list":["post-73374","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-git"],"acf":[],"blog_post_summary":"<p>Git works well for most development workflows. But a change that seems harmless can make a repository harder to work with. Here are a few examples of how that can happen. Committing binaries directly to your repository Binaries are more likely than source code files to differ a lot between versions, so delta compression is [&hellip;]<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts\/73374","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/users\/203892"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/comments?post=73374"}],"version-history":[{"count":2,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts\/73374\/revisions"}],"predecessor-version":[{"id":73766,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/posts\/73374\/revisions\/73766"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/media\/73428"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/media?parent=73374"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/categories?post=73374"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/devops\/wp-json\/wp\/v2\/tags?post=73374"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}