# Go: How slices grow

DevFeed: [Go: How slices grow](<https://devfeed.tech/articles/go-how-slices-grow-35403.md>)

Original publisher: [Read original article](<https://darkcoding.net/software/go-how-slices-grow/>)

Author: Graham King

Published: 2013-12-12T04:49:00Z

Content type: tutorial

Language: en

Sources: [Graham King](<https://devfeed.tech/sources/graham-king.md>)

Topics: [Go Language](<https://devfeed.tech/topics/go-language.md>), [Code](<https://devfeed.tech/topics/code.md>)

Tags: [array](<https://devfeed.tech/tags/array.md>), [capacity](<https://devfeed.tech/tags/capacity.md>), [garbage-collection](<https://devfeed.tech/tags/garbage-collection.md>), [go](<https://devfeed.tech/tags/go.md>), [growth](<https://devfeed.tech/tags/growth.md>), [make](<https://devfeed.tech/tags/make.md>), [memory](<https://devfeed.tech/tags/memory.md>), [slices](<https://devfeed.tech/tags/slices.md>), [software](<https://devfeed.tech/tags/software.md>)

## AI overview

This article explains how Go slices grow when append exceeds the backing array's capacity. It states that slices double in size up to 1024 elements, then grow by 25% per allocation, while noting that this is an implementation detail that may change. It recommends preallocating capacity when the approximate size is known to reduce allocations, copying, and garbage collection.

## Source excerpt

Uncover the hidden growth patterns of Go slices.