I would like to colour the background of a row in Google Spreadsheets:

For example:

  • If cell Dx = title 'To do' or 'title 'Done' then cells Fx to Nx are filled colour black.

  • If cell Dx = title 'closed' the font colour of cell Ax to Nx turns green.

I can do this in Excel quite easily...

  • 1
    As far as I know, such functionality has not been implemented in Google Spreadsheets. The only conditional formatting you can do is on the same cell with the value.
    – ale
    Sep 13, 2012 at 16:29
  • See also webapps.stackexchange.com/questions/16745/…
    – Caltor
    May 9, 2013 at 13:16

2 Answers 2


Where x = 1, in New Google Sheets in Custom formula is please try:

=or($D1="To do",$D1="Done")  

check Background:, choose black and for Range: enter F1:N1

add another rule with Custom formula is


check Background:, choose green and for range: enter A1:N1.


I wrote this web app - Color Code+ to cover most of the basic cases.

  • The example in your app, isn't editable. This way people can't see the result of your code: goo.gl/CFg61 Feb 6, 2013 at 7:29
  • You have to make your own copy of it and then you can access the code.
    – Bryan P
    Feb 6, 2013 at 13:24

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.