There are several Biblical passages that are worth considering with this question.
First, everything we do should be done for God's glory.
Whether therefore ye eat, or drink, or whatsoever ye do, do all to the
glory of God. (1 Corinthians 10:31, KJV)
How does pleasuring oneself, usually done in secret, bring glory to God?
Next, the Bible speaks of "youthful lusts." And we are told to "flee" them.
Flee also youthful lusts: but follow righteousness, faith, charity,
peace, with them that call on the Lord out of a pure heart. (2 Timothy
The word "lusts" is clear enough, and everyone knows, and often talks about, the "hormones" that youth experience.
We also know that there was an issue of "uncleanness."
16 And if any man's seed of copulation go out from him,
then he shall wash all his flesh in water, and be unclean until the
even. 17 And every garment, and every skin, whereon is the
seed of copulation, shall be washed with water, and be unclean until
the even. 18 The woman also with whom man shall lie with
seed of copulation, they shall both bathe themselves in water, and be
unclean until the even. 19 And if a woman have an issue,
and her issue in her flesh be blood, she shall be put apart seven
days: and whosoever toucheth her shall be unclean until the even.
(Leviticus 15:16-19, KJV)
Other texts confirm the importance of this issue of "cleanness," and appear to link "uncleanness" with "transgression" and "sin."
Thus shall ye separate the children of Israel from their uncleanness;
that they die not in their uncleanness, when they defile my tabernacle
that is among them. (Leviticus 15:31, KJV)
And of her that is sick of her flowers, and of him that hath an issue,
of the man, and of the woman, and of him that lieth with her that is
unclean. (Leviticus 15:33, KJV)
And he shall make an atonement for the holy place, because of the
uncleanness of the children of Israel, and because of their
transgressions in all their sins: and so shall he do for the
tabernacle of the congregation, that remaineth among them in the
midst of their uncleanness. (Leviticus 16:16, KJV)
That emission of "seed of copulation" caused uncleanness, even when part of the marriage act. While it was not a sin to have one's own spouse when married, during the woman's monthly period it was a sin for the man to "approach" his wife.
It is likely that God has more than one good reason for this monthly "week off." First, it helps the man (and woman) to learn self-restraint. It assists in breaking the orgasmic cycle for a period of time, reducing its addictive nature, and helping to preserve noble thoughts and lives. Secondly, a woman who is not following this "ceremonial" law of health may be at increased risk of endometriosis--where blood cells begin to be produced outside of the uterus in the woman's abdominal cavity. (Few doctors would be willing to jeopardize their status to acknowledge such an unpolitically correct possibility, but it makes perfect sense when one understands the mechanisms behind it, beginning with the flow of nucleated blood, and combined with orgasmic peristalsis. They do reference "retrograde menstruation" as a possible cause.)
The Bible says we are to do everything to God's glory. We are commanded to flee from youthful lusts. We are told that the emission of "seed of copulation" is a cause of uncleanness, and we know that any unnecessary uncleanness was to be strictly avoided (sex in marriage is permitted outside of the week of the woman's blood flow).
We know that the Biblical principle of love is to govern our lives, and that selfishness is love's opposite. Without question, masturbation is a selfish act, usually performed in secret, and with shame. God does not desire us to feel guilty nor ashamed. It is not God's will, therefore, for us to do something that would cause us to feel guilty--this would not be to God's glory.
The principles add up to one conclusion: masturbation is not part of God's plan.
For all that is in the world, the lust of the flesh, and the lust of
the eyes, and the pride of life, is not of the Father, but is of the
world. (1 John 2:16, KJV)