Nearly 100 Northern Virginians spoke up last night about the state's first attempt to mandate sex education in public schools, with local educators pressing for the freedom to implement programs that are more comprehensive than the one under consideration.

"The Alexandria School Board is seriously concerned that the state's curriculum guidelines will radically diminish and infringe upon Alexandria's comprehensive program," said Alexandria School Board member Sandra Lindsay.

Lindsay and speakers from Arlington, Fairfax and other Virginia school districts argued at a hearing before representatives of the State Board of Education that the state's guidelines should be flexible enough to allow local school systems to tailor basic curriculum objectives to individual needs.

The State Board of Education's draft proposal sets out a grade-by-grade guideline for teaching about human sexuality from kindergarten through high school. The board has not yet decided whether the curriculum it adopts should replace family life courses already being taught in many of the state's school systems.

Under the draft proposal, in kindergarten, pupils would learn the correct terminology for body parts and functions. In second grade they would learn to judge sexually explicit advertising, and in third grade would learn about reproduction with an emphasis on birth within marriage. In sixth grade they would discuss masturbation and adverse consequences of nonmarital sex.

Students in fourth through eighth grades would be separated by sex during sensitive discussions, such as puberty, personal hygiene and physiological changes.

The most controversial elements of the proposal, which were completed by the board's staff last week, were left out of the discussion because they have not been reviewed by all members of the state board.

The additional recommendations suggest that a discussion on contraceptives and homosexuality begin in seventh grade and that abortion be discussed soon afterward, said Jean Bentley, associate director of health, physical education and drivers education for the state board. Information on acquired immune deficiency syndrome would begin in fifth grade.

The Virginia General Assembly asked the Board of Education this year to come up with a comprehensive sex education study plan after a subcommittee had studied the problem of teen-age pregnancy in the state. The board intends to vote on a final plan at its Nov. 16 meeting and to submit it to the legislature Dec. 1.

If adopted, every school district in Virginia would be required to offer family life courses by 1989.

The estimated cost to implement the program, for such things as text books and teacher training, is $4.02 million for the first year and $1.48 million each year after that, Bentley said.

Local educators who spoke before the panel at Francis C. Hammond Junior High School in Alexandria criticized the proposal for not teaching the positive aspects of human sexuality. They also said teachers should receive more training than the state proposes and that local decisions on curriculum should be respected.

Ignoring the existing family life curriculum "could result in a large number of parents taking their children out of the program," said Robert Mead, director of pupil personnel services for Warren County schools.

The proposal recommends that parents be allowed to withdraw their children from parts of the curriculum.

As at other meetings that have discussed sex education in schools, the audience was divided. Opponents of the proposal said the subject should be left to parents, that teaching it is an invasion of privacy and usurps traditional family values.

The state board will consider adding instruction on birth control and abortion to the curriculum at its Oct. 22 meeting in Richmond.