{"id":21322,"date":"2024-02-18T12:02:08","date_gmt":"2024-02-18T11:02:08","guid":{"rendered":"https:\/\/minecraft-tutos.com\/?p=21322"},"modified":"2024-02-18T12:02:13","modified_gmt":"2024-02-18T11:02:13","slug":"how-do-i-use-the-xp-and-experience-commands-in-minecraft","status":"publish","type":"post","link":"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/","title":{"rendered":"How do I use the \/xp and \/experience commands in Minecraft ?"},"content":{"rendered":"\n<p>The <strong>\/experience or \/xp command in Minecraft<\/strong> lets you add, delete or view a player&#8217;s experience. It&#8217;s a powerful tool that can be used to manipulate a player&#8217;s experience points or levels, and this <a href=\"https:\/\/minecraft-tutos.com\/en\/minecraft-commands-complete-list-of-the-most-useful-ones\/\">Minecraft command<\/a> is available in different versions of Minecraft, including Java Edition and Bedrock Edition.<\/p>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_80 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-69e34507463df\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-69e34507463df\"  aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#experience-command-syntax\" >\/experience command syntax<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#How-to-enter-the-experience-command\" >How to enter the \/experience command<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#Examples-of-use\" >Examples of use<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#Explanations-on-arguments\" >Explanations on arguments<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#Differences-between-xp-and-experience\" >Differences between \/xp and \/experience<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/minecraft-tutos.com\/en\/how-do-i-use-the-xp-and-experience-commands-in-minecraft\/#Additional-information\" >Additional information<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"experience-command-syntax\"><\/span>\/experience command syntax<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>The syntax of the <code>\/experience<\/code> command varies depending on whether you want to add, set or query a player&#8217;s experience. Here are the main forms of the command:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>To add experience : <code>\/experience add &lt;targets&gt; &lt;amount&gt; [levels|points]<\/code><\/li>\n\n\n\n<li>To set experience : <code>\/experience set &lt;targets&gt; &lt;amount&gt; [levels|points]<\/code><\/li>\n\n\n\n<li>To query the experience : <code>\/experience query &lt;targets&gt; (levels|points)<\/code><\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"How-to-enter-the-experience-command\"><\/span>How to enter the \/experience command<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Open the chat window :<\/strong> The key to open the chat window depends on the version of Minecraft you&#8217;re using (for example, the T key for Java Edition).<\/li>\n\n\n\n<li><strong>Type command :<\/strong> Enter the appropriate command depending on what you want to do (add, set or query experience).<\/li>\n\n\n\n<li><strong>Press Enter :<\/strong> Press Enter to execute the command.<\/li>\n<\/ol>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Examples-of-use\"><\/span>Examples of use<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>To give 20 levels of experience to the player called keither : <code>\/xp add keither 20 levels<\/code><\/li>\n\n\n\n<li>To remove 3 experience points from all players : <code>\/xp add @a -3 points<\/code><\/li>\n\n\n\n<li>To set a random player&#8217;s experience levels to 50 : <code>\/xp set @r 50 levels<\/code><\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Explanations-on-arguments\"><\/span>Explanations on arguments<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code><strong>&lt;targets&gt;<\/strong><\/code> : Command target, can be a player name, a target selector or a UUID.<\/li>\n\n\n\n<li><strong><code>&lt;amount&gt;<\/code><\/strong> : Amount of experience points or levels to give, set or query. Negative values remove experience.<\/li>\n\n\n\n<li><strong><code>[levels|points]<\/code><\/strong> : Specifies whether the quantity is in levels or experience points.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Differences-between-xp-and-experience\"><\/span>Differences between \/xp and \/experience<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>The <code>\/xp<\/code> and <code>\/experience<\/code> commands are used to manipulate player experience in Minecraft, but there are a few key differences between them:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Alias :<\/strong> The <code>\/xp<\/code> command is an alias of the <code>\/experience<\/code> command. This means that in some versions of Minecraft, you can use these commands interchangeably. For example, <code>\/xp add &lt;player&gt; 10 levels<\/code> is identical to <code>\/experience add &lt;player&gt; 10 levels<\/code>.<\/li>\n\n\n\n<li><strong>Syntax :<\/strong> Although both commands perform similar functions, the syntax may vary slightly between Minecraft versions. In some versions, the <code>\/experience<\/code> command offers more options and flexibility, such as the ability to set or query a player&#8217;s experience.<\/li>\n\n\n\n<li><strong>Supported version :<\/strong> The <code>\/experience<\/code> command is generally supported in more recent versions of Minecraft, while the <code>\/xp<\/code> command can be used in older versions. However, in versions where both are supported, they work in a similar way.<\/li>\n\n\n\n<li><strong>Usage :<\/strong> The <code>\/xp<\/code> command is often used to add experience points or experience levels to a player, while the <code>\/experience<\/code> command can also be used to set or query a player&#8217;s experience.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Additional-information\"><\/span>Additional information<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Supported versions :<\/strong> The command is available in various versions, including Java Edition (from 1.3.1) and Bedrock Edition.<\/li>\n\n\n\n<li><strong>Using the L attribute :<\/strong> The L attribute can be used with the <code>\/xp<\/code> command to add experience levels to a player, filling an entire experience bar.<\/li>\n\n\n\n<li><strong>Requirements :<\/strong> To execute game commands in Minecraft, you need to enable cheats in your world.<\/li>\n<\/ul>\n\n\n\n<p>The <code>\/experience<\/code> command is a versatile tool that offers players and server administrators great flexibility in managing experience in Minecraft. Whether you want to reward a player with extra points or reset a player&#8217;s experience to a specific level, this command gives you the means to do so.<\/p>\n\n\n<div class=\"kk-star-ratings kksr-auto kksr-align-center kksr-valign-bottom\"\n    data-payload='{&quot;align&quot;:&quot;center&quot;,&quot;id&quot;:&quot;21322&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;2&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;4&quot;,&quot;greet&quot;:&quot;Rate this post&quot;,&quot;legend&quot;:&quot;5 \\\/ 5 - (2 votes)&quot;,&quot;size&quot;:&quot;20&quot;,&quot;title&quot;:&quot;How do I use the \\\/xp and \\\/experience commands in Minecraft ?&quot;,&quot;width&quot;:&quot;118&quot;,&quot;_legend&quot;:&quot;{score} \\\/ {best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}'>\n            \n<div class=\"kksr-stars\">\n    \n<div class=\"kksr-stars-inactive\">\n            <div class=\"kksr-star\" data-star=\"1\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"2\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"3\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"4\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" data-star=\"5\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n    <\/div>\n    \n<div class=\"kksr-stars-active\" style=\"width: 118px;\">\n            <div class=\"kksr-star\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n            <div class=\"kksr-star\" style=\"padding-right: 4px\">\n            \n\n<div class=\"kksr-icon\" style=\"width: 20px; height: 20px;\"><\/div>\n        <\/div>\n    <\/div>\n<\/div>\n                \n\n<div class=\"kksr-legend\" style=\"font-size: 16px;\">\n            5 \/ 5 - (2 votes)    <\/div>\n    <\/div>\n","protected":false},"excerpt":{"rendered":"<p>The \/experience or \/xp command in Minecraft lets you add, delete or view a player&#8217;s experience. It&#8217;s a powerful tool<\/p>\n","protected":false},"author":2,"featured_media":21323,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"pgc_sgb_lightbox_settings":"","footnotes":""},"categories":[30],"tags":[],"class_list":["post-21322","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-how-to","generate-columns","tablet-grid-50","mobile-grid-100","grid-parent","grid-50"],"_links":{"self":[{"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/posts\/21322","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/comments?post=21322"}],"version-history":[{"count":1,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/posts\/21322\/revisions"}],"predecessor-version":[{"id":21329,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/posts\/21322\/revisions\/21329"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/media\/21323"}],"wp:attachment":[{"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/media?parent=21322"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/categories?post=21322"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/minecraft-tutos.com\/en\/wp-json\/wp\/v2\/tags?post=21322"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}