Ever gotten deep into building out a gradient in Illustrator and then wanted to save the gradient colors as swatches? You’re not going to believe how easy it is!
With your artwork selected and the gradient active, all you need to do is click the New Color Group button at the bottom of the Swatches panel. Voilà, all your gradient colors are added just like that!

Click the New Color Group button at the bottom of the Swatches panel to capture all the colors in the active gradient as swatches.

In the New Color Group dialog, name your color group and choose the Create From Selected Artwork radio button. Click OK to create a color group from the active gradient.

The new color group with all the gradient colors appears at the bottom of the Swatches panel.