Would a uranium 235 fuel pellet the size of Earth explode? Imagine a standard $^{235}\text{U}$ pellets scaled to the scale of Earth, I wonder, would it explode or just meltdown? I believe despite overshooting the critical mass, the heat produced is still too small to start sustained chain reaction? Right?
 A: Some assembly required
The problem with making a nuclear bomb go "boom" is holding it together to actually go boom.  Normally, when a critical mass is achieved, the excursion  (exponential increase) in energy causes something to happen that disassembles the critical mass. 


*

*The thing that didn't happen to Dahlgren and Slotin (because they yanked the reflector away immediately) - happened with the Lady Godiva robotic device. The energy excursion ran long enough to have effects which pushed the reflector away (and broke the device. 

*Chernobyl clearly suffered an excursion, which flash-boiled steam so violently as to blow the reactor to kingdom come, breaking up the critical mass and ending the reaction.  All the following trouble came from plain fire (graphite likes to burn), possibly being rekindled by decay heat. 


So the normal state-of-affairs is for the critical mass to create just enough energy to blow itself into sub-critical pieces.  
So if you want anything funner than Chernobyl to happen, i.e. a useful bomb, then it's all about holding the critical mass together longer than it would stay naturally. This is the essence of bomb-making.
But yet, also, having the mass be sub-critical up until the moment you hit the red button. 
Honestly, it's sorta spooky that a random citizen would know any of this. But the Cold war is over, and duck-and-cover has faded into nostalgia, making atom bomb tech quaint -- fair game for The History Channel or Nova, alongside steam engines and the Glomar Explorer caper.
The normal ways
U235 is generally associated with a "gun-type" device (Thin Man/Little Boy), taking two subcritical masses and slamming them together as fast as possible. 
Cutting it in  half won't work in an Earth-sized chunk of U235.  Because each half would still be critical. 
The normal method with plutonium is to build a sphere which is sub-critical at STP, but becomes critical when compressed by an outer sphere of high explosives detonated perfectly. At first glance, that won't work either because an Earth sized ball of U235 is in fact critical at STP.  
However, we can make the ball hollow. By introducing a void in the middle of the sphere, the mass is sub-critical. 
A pretty big ball, though
A 169mm sphere of uranium will go critical all by itself.  To keep that from happening, we'll armwave (to avoid the heavy math) that a 120mm thick sheet of U235 will not go critical, and we'll build our hollow ball with that shell thickness. 
Let's introduce a fun unit called "Mega-Metres", or 1000 km.  About the distance you could drive in a day.  
Earth's volume is 1083.21 cubic Mega-metres or cMm.  So we need a ball large enough that its 120mm thick shell has that volume.   Crunched the numbers with a bit of code, and the answer pops out "26801.71 mega-metre radius" or 26,801,710 kilometre radius.
That is 0.179158 Astronomical Units.  Of radius. Well inside the orbit of Mercury. 
Anyway, now we're going to pack the outside of this thing with high explosives to make it implode. Since uranium is a pretty strong metal, and it's a sphere which is naturally very strong, this will be a LOT of high explosives -- hundreds or even thousands of Earth volumes of high explosives, which begs the question of why not just use that stuff directly. 
Of course, this beast is 3.00 light-minutes across, so it'll take weeks to assemble.  By the time it shrinks 25%, the shell thickness will be 160 mm, and that in a flat surface will definitely be a critical mass. Thus, the shell will burn with nuclear fury, eventually overwhelming the energy invested by the high explosives, and reversing the implosion.  At that point, the shell will simply push outward until criticality is lost and, once again, the critical mass self-disassembles, sending subcritical masses of U235 hurtling in all directions, surely with escape velocity. They will never reassemble.   
But what are we doing?  We have a Dyson Sphere.
You don't blow that up!  You live on it.  
OK, I'll grant you 0.18 AU might be a little too good for your tan. But there's no question that you're capable of building a Rather Nice ringworld at a nice comfy 1 AU, out of cheap/normal/readily available iron/steel (it is the bottom of the fusion chain, after all, so there's loads of it), rather than rare U235. 
So woot, we have a ringworld! 
A: It is worth noting that there is no such thing as a critical mass: there is a critical condition where there is enough mass, neutron reflection and other shape properties to make a chain reaction run to completion rather than produce some heat or a fizzle.
Still, a huge sphere of U235 will not just sit there. 50 kg of uranium-235 is the bare sphere critical mass of uranium-235, that is, it will become critical even without reflectors (see the linked paper by Chyba and Milne for calculations). For a huge sphere the neutron mean free path $\lambda_f = 16.9$ cm will be far less than the radius and all neutrons in the core hit something. That some of the surface is too "cold" to react does not matter if much of the bulk does.
There is a final issue: can the explosion overcome the gravitational binding energy of a huge lump of uranium? I we assume one earth mass of uranium at normal density I get $R=4210$ km and $E_{binding}=3.4\cdot 10^{32}$ J. U235 fission releases about 82 TJ per kg. So the nuclear energy that can be released is $4.9\cdot 10^{38}$ J, or 1.4 million times the binding energy. So, yes, it will explode even if the reaction is fairly inefficient: even a fizzle would turn it into plasma.
A: A critical mass of U-235 fuel is only 17 centimeters in diameter and weighs 52 kilograms. A sphere of U-235 the size of the earth would be impossible to assemble because it would go critical and explode long before you could get it that big.
The heat generated at criticality is not what sustains the chain reaction, it is the neutron flux released by the fissioning uranium atoms. 
A: It is conceivable that Jupiter might have a radioactive center the size of a planetoid or planet.  The high specific gravity of uranium and thorium suggests they might co-locate towards the center of a planet.  The possibility of going critical seems more than just an academic question.
While uranium and thorium compounds (like oxides) have a lower density, one might expect these compounds to be chemically reduced in planetary interiors.  Perhaps the Earth might have experienced, or is currently experiencing, fission in its interior.
A: Yes , it explodes ...
From many points at the same time , because it contains a very great number of elementary critical mass if highly enriched 235U  fuel : it is only a big 235U bomb .
Under 20%  enrichement ( approx. value  ) , there is not critical mass for 235U  , so nothing happens .
A: wrt a critical mass of U-235, the responders are correct in their observations about the need to hold the mass together long enough for a significant fraction of the mass of U-235 to fission in a very short space of time, releasing significant energy in the form of heat. 
The issue of moderated neutrons is a red herring. This is what is necessary in a nuclear (aka fission) reactor where we look for a high rate of absorption of the neutrons without going critical. The moderators (graphite, heavy water, et al) are used to slow down and reflect the neutrons to thermal levels so a sustained but non-critical sustained chain reaction can occur. Further, the ratio of U-235 to U-238 in nuclear power stations is much, much lower than weapons-grade uranium so the reactor does not go explosively critical.
As for the size of a critical mass - and the configuration - the experiment with the mouse traps and ping-pong balls (look it up on the internet) is illustrative. In a room with perfectly reflective hard walls, all ping-pong balls get reflected back into the room, setting off just about all of the traps. If the experiment were run in an open field, with now walls, then the critical 'mass' of ping-pong ball-loaded traps would be correspondingly higher as many ping-pong balls (aka neutrons) would escape into the environment. 
The question about the critical mass is, as noted elsewhere, about the critical volume, which is dependent upon the efficiency of capture of the fast neutrons and there being enough U-235 atoms present to capture enough of them to go critical - i.e. bang. U-238 is more likely to capture thermal (slowed) neutrons so the fast neutrons from U-235 decay don't interact with U-238 that well - that's why they have to concentrate the U-235 to about 90% purity to get material that will go critical.
As for assembling some weapons-grade uranium to the 'size of the earth' well you would not get it together before it either went bang, or released enough radiation to kill all of those working on the project. Slotin, who worked on the Manhattan Project, suffered a lethal does of radiation when two sub-critical masses of enriched U-235 briefly came in contact. Any attempt at some large assembly of uranium would kill everyone in sight.
