Q:

How is moduli of curves relevant in physics?

From: Moduli space
we see that moduli of curves is a very algebro-geometric topic. 
It is easy to understand its relevance and importance in algebraic geometry. But the mind boggles when we try to imagine how on earth such a topic from pure and abstruse mathematics is relevant in physics. 
I will be thankful if somebody can give some explanation.

A:

In string theory, a particle is actually a string.  In closed string theory, it is a closed string, i.e. a loop.  As time progresses, this loop will trace out a surface (its worldsheet).  If you follow the particle from its creation to its destruction, this surface will be closed.  
For certain computations of physical quantities attached to the worldsheet (and perhaps at this point someone with more expertise can add details) one has to choose a conformal structure on the worldsheet; but to get an answer independent of the choice, one then integrates over all possible conformal structures; or sometimes one can show that the quantity computed is independent of the conformal structure (perhaps because it is computed by a horizontal section of a bundle with connection over the space of conformal structures). 
Finally, we note that the space of all conformal structures on a closed topological surface of genus $g$ is the same as the moduli space of algebraic curves of genus $g$.  

A:

In quantum field theory many quantities are calculated as (formal) Feynman path integrals, that is, integrals "over the space of all paths".  To make sense of this in dimensions higher than 2, one uses a perturbation expansion (in powers of Planck's constant) of the integral which leads to a sequence of finite dimensional integrals described by Feynman diagrams: finite graphs with (among other decorations) some "input" and "output" vertices --- think of a process where some particles collide and some are emitted.
In string theory instead of a sum over paths of a point there is a sum over trajectories of a closed loop (a string), i.e., integration over some space of surfaces.  The analogue of the finite-dimensional perturbative Feynman diagrams are surfaces connecting some oriented loops. Loops with positive orientation relative to the surface are the "inputs" and the others are the "outputs".  The surface can also have empty input or output.  Integration over all surfaces of this type is still an infinite-dimensional problem.  To reduce to a finite-dimensional integral, one integrates over the moduli space of conformal structures on each topological type of bordered surface.  This is finite-dimensional and there are standard measures on it (Weil-Petersson).  For problems with conformal invariance ("conformal field theory") this recipe was given by Polyakov and is basic for string theory.   As far as I understand it, the worldsheet is always governed by a conformal field theory, so the Polyakov recipe is "the" method for defining the observables in perturbative string theory.   
Also, for open strings one might want the boundaries to be open circles, or punctures, thus cutting out closed discs or points from the surface.   So the general moduli space is that of  conformal structures on surfaces of a fixed finite genus with a given finite type of boundary and one can at least define a measure on this space.  Rigorous calculations can be extremely complicated as seen in the arxiv papers by D'Hoker and Phong where they went through a huge tour-de-force to construct the perturbative superstring measure through 2 and 3 loops.
As Matt explained, the relation to algebraic geometry is that (at least for compact surfaces without boundary) the moduli space of conformal structures is the same as that of algebraic structures; in each conformal class there is an algebraic curve of that genus.  I am less sure of this in the non-compact case of punctured surfaces, and for bordered Riemann surfaces where the boundary contains loops, the moduli space is of geometric/symplectic/complex-analytic nature and I don't know if it has an algebraic analogue.
(edit: I think that there is a basic difference between QFT and string theory in this analogy, because in string theory only the perturbative measure is known at present, while in QFT path-space integrals are thought of as an underlying non-perturbative theory and one can make sense of that to a large extent even if Feynman's "measure" on path space doesn't exist as an integration measure in the ordinary mathematical sense.   In string theory the non-perturbative definition of the theory is presently unknown.  There are objects in string theory that are considered non-perturbative and thus hints of the underlying theory, but even conjecturally or heuristically there is not a consensus as to what perturbative string theory is a perturbation of.)
(added: 
According to this paper, for bosonic string theory in Polyakov's prescription, the moduli spaces in the perturbative integrals are those of smooth closed surfaces, without punctures or boundary loops.  This is interesting because conformal field theory does use the more complicated surfaces, but I don't know the details of how CFT is used in string theory.
http://projecteuclid.org/DPubS?service=UI&version=1.0&verb=Display&handle=euclid.cmp/1104116138   )

