I have traced a photo in Illustrator, resulting in a complicated vector image with 20 colours.

I would like to add a stroke to all of the shapes in the image and set the stroke colour to be the same as the fill colour of each individual shape, e.g. shapes filled red will have a red stroke and shape filled blue will have a blue stroke.

Is there an option which does this automatically, or will I have to set the stroke colour of each shape individually?

  • 1
    Was there ever any answer to this - it seems like something that the program should do automatically.
    – James
    Commented Nov 5, 2014 at 17:56
  • Relevant (or duplicate) graphicdesign.stackexchange.com/questions/41767/…
    – Scott
    Commented Nov 5, 2014 at 19:30
  • Thanks @Scott - definitely relevant. Hadn't considered a custom script. Commented Feb 26, 2015 at 20:04
  • Is there any better solution to this than a custom script? Is Illustrator stuck in the 80' in this regard? Commented Mar 14, 2021 at 17:49

2 Answers 2


You can sort of do this in Illustrator by expanding the paths themselves, instead of using a stroke.

  1. Select all objects and set their strokes to none
  2. Use the menu command Object → Path → Offset Path…
  3. Use the Offset amount to increase the width of your shape while retaining the fill color

For more information watch: http://youtu.be/lS1HDKRGVe0


Not a solution, but a workaround: you can use the Magic Wand tool to select all shapes that have identical (or very similar, depending on your settings) fill colour, all at once. When they are selected, you can give them all the same fill colour.

You'll still have to repeat the process for each colour, but 40 clicks (two for each colour) still better than a few hundred...

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.