Online Chromatic Number is PSPACE-Complete


In the online graph coloring problem, vertices from a graph G, known in advance, arrive in an online fashion and an algorithm must immediately assign a color to each incoming vertex v so that the revealed graph is properly colored. The exact location of v in the graph G is not known to the algorithm, since it sees only previously colored neighbors of v. The online chromatic number of G is the smallest number of colors such that some online algorithm is able to properly color G for any incoming order. We prove that computing the online chromatic number of a graph is PSPACE-complete.

This is a preview of subscription content, access via your institution.

Fig. 1
Fig. 2
Fig. 3
Fig. 4


  1. 1.

    Bean, D.R.: Effective coloration. J. Symb. Log. 41(2), 469–480 (1976)

    MathSciNet  Article  MATH  Google Scholar 

  2. 2.

    Bodlaender, H.: On the complexity of some coloring games. Int. J. Found. Comput. Sci. 2.02, 133–147 (1991)

    MathSciNet  Article  MATH  Google Scholar 

  3. 3.

    Böhm, M., Veselý, P.: Online chromatic number is PSPACE-complete. In: Proceedings of 27th international workshop on combinatorial algorithms (IWOCA 2016). LNCS 9843, pp. 16–28 (2016)

    Google Scholar 

  4. 4.

    Csernenszky, A., Martin, R.R., Pluhár, A.: On the complexity of Chooser-Picker positional games. arXiv:1605.05430 (2016)

  5. 5.

    Dvořák, P., Valla, T.: On the computational complexity and strategies of online Ramsey theory. In: Proceedings of 8th European conference on combinatorics, graph theory and applications (EuroComb 2015), vol. 49, pp. 729–736 (2015)

    Google Scholar 

  6. 6.

    Gyárfás, A., Lehel, J.: First fit and on-line chromatic number of families of graphs. Ars Combinatoria 29C, 168–176 (1990)

    MathSciNet  MATH  Google Scholar 

  7. 7.

    Gyárfás, A., Kiraly, Z., Lehel, J.: On-line graph coloring and finite basis problems. Combinatorics: Paul Erdos is Eighty 1, 207–214 (1993)

    MathSciNet  MATH  Google Scholar 

  8. 8.

    Halldórsson, M.M.: Parallel and on-line graph coloring. J. Algorithms 23, 265–280 (1997)

    MathSciNet  Article  MATH  Google Scholar 

  9. 9.

    Halldórsson, M.M.: Online coloring known graphs. Electron. J. Comb. 7(1), R7 (2000)

    MathSciNet  MATH  Google Scholar 

  10. 10.

    Halldórsson, M.M., Szegedy, M.: Lower bounds for on-line graph coloring. Theor. Comput. Sci. 130.1, 163–174 (1994)

    MathSciNet  Article  MATH  Google Scholar 

  11. 11.

    Kierstad, H.: On-line coloring k-colorable graphs. Israel J. Math. 105, 93–104 (1998)

    MathSciNet  Article  Google Scholar 

  12. 12.

    Kudahl, C.: On-line graph coloring. Master’s thesis, University of Southern Denmark (2013)

  13. 13.

    Kudahl, C.: Deciding the On-line chromatic number of a graph with pre-coloring is PSPACE-complete. In: Proceedings of 9th international conference on algorithms and complexity (CIAC 2015). LNCS 9079. arXiv:1406.1623, pp. 313–324 (2015)

    Google Scholar 

  14. 14.

    Lovász, L., Saks, M., Trotter, W.T.: An on-line graph coloring algorithm with sublinear performance ratio. Ann. Discrete Math. 43, 319–325 (1989)

    MathSciNet  Article  MATH  Google Scholar 

Download references


The authors thank Christian Kudahl and their supervisor Jiří Sgall for useful discussions on the problem.

Author information



Corresponding author

Correspondence to Pavel Veselý.

Additional information

This article is part of the Topical Collection on Special Issue on Combinatorial Algorithms

Supported by project 17-09142S of GA Č R and by the GAUK project 634217. Apreliminary version of this work appeared in [3].

Rights and permissions

Reprints and Permissions

About this article

Verify currency and authenticity via CrossMark

Cite this article

Böhm, M., Veselý, P. Online Chromatic Number is PSPACE-Complete. Theory Comput Syst 62, 1366–1391 (2018).

Download citation


  • PSPACE-completeness
  • Online coloring
  • Online chromatic number