By · Updated

PlaceholderAPI placeholders not working: fix %placeholder% showing as text

14commands
2files
6min read
Sheet 11 of 20 · server owners

Filesconfig.yml · messages.yml

Fileconfig.ymlFilemessages.ymlCommand/papi parse me %player_name%Command/papi listA placeholder shows up as raw text, like %player_name% on a scoreboard, when nothing replaced it. For it to work three things have to be true: PlaceholderAPI is installed and enabled, an expansion for that identifier is registered, and the plugin that displays the text passes it through PlaceholderAPI. One command tells you which of the three is broken: /papi parse me %player_name%.

How PlaceholderAPI works

Fileconfig.ymlPlaceholderAPI on its own provides no placeholders. Its config.yml says so in the first lines. Every placeholder comes from an expansion, and an expansion comes from one of two places:

  • Command/papi listCommand/papi ecloud list installedCommand/papi ecloud downloadBuilt into a plugin. The plugin registers its own expansion when it starts. Nothing to download. /papi list shows it, /papi ecloud list installed does not, and /papi ecloud download for it fails because there is nothing on the eCloud to download.
  • Command/papi reloadA jar from the eCloud. Expansions like Player, Server, Statistic and Math are separate jars that land in plugins/PlaceholderAPI/expansions/. They are only active after /papi reload.

The plugin that shows the text, your scoreboard, tab list, hologram or menu plugin, then has to hand the text to PlaceholderAPI before it draws it. If it does not, no expansion in the world helps.

Find the broken part

    1. Parse it yourself

      Command/papi parse me %player_name%Command/papi parseRun /papi parse me %player_name% in game, or /papi parse <player> %player_name% from the console. Use the exact placeholder from your config, not one you typed fresh.

    2. It came back with a value

      PlaceholderAPI and the expansion are fine, so the plugin showing the text is the problem. Check that it supports PlaceholderAPI at all, and that you put the placeholder in a field it parses. See the displaying plugin.

    3. It came back as the same text

      Command/papi listThe expansion is missing, not loaded, or the placeholder is misspelled. Run /papi list to see the registered identifiers. The identifier is the part between the first % and the first _.

    4. The identifier is not in the list

      Command/papi ecloud download PlayerCommand/papi reloadInstall the expansion. For eCloud ones run /papi ecloud download Player (the name, not the identifier), then /papi reload. For a plugin's own expansion, check that the plugin is enabled with /plugins and that its PlaceholderAPI hook is turned on in its config.

    5. It is in the list and still does not parse

      Command/papi ecloud placeholdersLook the placeholder up with /papi ecloud placeholders <expansion> or in the plugin's docs. Most failures at this point are a typo, a missing argument or a placeholder that needs an online player.

Symptoms and fixes

You seeCauseFix
%vault_eco_balance% as text, /papi parse tooExpansion not installed/papi ecloud download Vault, then /papi reload
Downloaded it, still rawNo reload since the download/papi reload
/papi parse works, the scoreboard shows raw textThe scoreboard plugin does not parse PlaceholderAPI in that fieldMove it to a field that does, or use a plugin that supports it
{player_name} stays as textThe plugin only parses the %...% formUse %player_name%
%rel_...% stays as textRelational placeholders need two players and their own callTest with /papi parserel; the displaying plugin must support relational ones
Empty value for some playersThe placeholder needs an online playerUse a placeholder that works offline, or show it only to online players
ecloud download refused or times outFirewall, an old PlaceholderAPI, or the version is not verifiedSee eCloud downloads
Failed to load expansion class in the consoleThe expansion needs a plugin that is not installedInstall that plugin, or remove the expansion jar

The plugin that displays the text

This is the cause people check last and the most common one. PlaceholderAPI does nothing on its own: each plugin decides which of its text fields go through it. A tab list plugin may parse the header but not player names. A hologram plugin may parse lines but not the hover text. Some chat plugins need an extra add-on before they parse anything.

Placeholder%arena%Filemessages.ymlFileconfig.ymlA plugin's own placeholders are a separate thing too. {player}, <name> or %arena% in a plugin's messages.yml are often its own variables, filled by the plugin, and PlaceholderAPI placeholders in the same file may not be parsed at all. IgnitePaste is an example: its <name>-style placeholders in config.yml and messages.yml are its own, and PlaceholderAPI placeholders are not parsed there. Its expansion is for other plugins to read IgnitePaste's data, not the other way round.

Placeholder%player_name%So read the displaying plugin's docs for the exact fields that support PlaceholderAPI, and test with a placeholder you know works, %player_name%, before blaming the expansion.

Syntax mistakes that look like bugs

  • Placeholder%identifier_value%Percent signs, not braces. %identifier_value% is the standard form. Braces only work in plugins that ask PlaceholderAPI for the bracket form.
  • Placeholder%server_online%Placeholder%something%An underscore after the identifier. Since PlaceholderAPI 2.12.3, a standard placeholder needs an underscore after the identifier to count, the same rule relational placeholders already had. %server_online% is fine; a bare %something% that worked before the update may not.
  • Arguments in the name. Many placeholders carry an argument, like %ignitezombies_arena_<name>_wave%. Leaving the <name> part as it is, angle brackets and all, gives you nothing.
  • Case and spelling. Copy placeholders from the expansion's list instead of typing them.
  • Command/papi parse --nullOffline players. Some placeholders read live data only an online player has. /papi parse --null <text> tests placeholders that need no player at all, which is what a hologram or a sign with no viewer uses.

eCloud downloads that fail

Three changes in the last releases explain most failed downloads:

  • Config keyapi.extendedclip.comNew address. From 2.12.0 PlaceholderAPI downloads from *.placeholderapi.com instead of api.extendedclip.com. A host or firewall that only allowed the old address blocks the new one. curl -I https://ecloud.placeholderapi.com/api/v3/ from the server machine shows whether it gets through.
  • Command/papi ecloud downloadVerified versions only. Since 2.12.1 each expansion version is verified on its own, and /papi ecloud download only fetches verified versions. A brand new upload that is not verified yet has to be installed by hand.
  • Fileconfig.ymlCloud switched off. If cloud_enabled is false in config.yml, the eCloud commands tell you to turn it back on and reload.

Command/papi reloadTo install an expansion by hand, put its jar in plugins/PlaceholderAPI/expansions/ and run /papi reload. Only take jars from the expansion's own page or repository.

Commands worth knowing

CommandWhat it does
/papi parse <player|me|--null> <text>Shows the text after parsing
/papi parserel <player> <player> <text>The same for relational placeholders
/papi listEvery registered expansion, built-in ones included
/papi info <expansion>Author, version and placeholders of one expansion
/papi ecloud download <expansion> [version]Downloads an eCloud expansion
/papi ecloud update <expansion|all>Updates downloaded expansions
/papi ecloud placeholders <expansion>Lists the placeholders an eCloud expansion has
/papi reloadReloads the config and the expansions
/papi dumpUploads versions and installed expansions, for a support request

The command nodes default to op.

Folia

PlaceholderAPI declares Folia support since 2.11.7, with a note that not every expansion has been tested there. An expansion that reads world data from the wrong thread can still fail on Folia even though PlaceholderAPI loads. More on what Folia support means in practice is in Folia plugins: how to check.

Placeholders from our plugins

Each of these registers its expansion on startup when PlaceholderAPI is installed, so there is nothing to download from the eCloud:

PluginIdentifierExampleFull list
IgniteSkyignitesky%ignitesky_level%, %ignitesky_bank%Integrations & Placeholders
Ignite Zombiesignitezombies%ignitezombies_wave%, %ignitezombies_arena_<name>_players%Placeholders
IgnitePasteignitepaste%ignitepaste_buildings%, %ignitepaste_cooldown_time_<name>%PlaceholderAPI

Config keyplaceholders.enabledFileconfig.ymlIgnitePaste's expansion also has a switch, placeholders.enabled in config.yml, on by default. If its placeholders show as text while the others work, check that first. Its server-wide stats like %ignitepaste_stats_pastes_<name>% need no player, so they work in holograms and with --null, while the building cap placeholders read permissions and stay empty for offline players.

Where to go next

Written from

  1. PlaceholderAPI wiki: FAQ
  2. PlaceholderAPI wiki: Commands
  3. PlaceholderAPI wiki: Common issues and blocked eCloud
  4. PlaceholderAPI releases: 2.11.7 Folia, 2.12.1 verified versions, 2.12.3 underscore rule
  5. PlaceholderAPI config.yml