Use utf8mb4 encoding in database by default?

  • Context: I was looking into why emoji that came through via Webmentions were displaying as ???? (4 question marks) on my Perch site. It looks like this is, because emoji require 4 bytes and utf8, used for encoding DB by default, does not support 4 byte characters. However, utf8mb4 does!


    I updated my Perch databases and set PERCH_DB_CHARSET to utf8mb4. I wondered though, would utf8mb4 be a sensible default, as emoji are wildly popular these days?

  • drewm

    Approved the thread.