In Hindu philosophy, Sakshi (Sanskrit: साक्षी), also Sākṣī, "witness," refers to the 'pure awareness' that witnesses the world but does not get affected or involved. Sakshi is beyond time, space and the triad of experiencer, experiencing and experienced; sakshi witnesses all thoughts, words and deeds without interfering with them or being affected by them. Sakshi or Shiva, along with Shakti (will/energy/motion), represents the Brahman, the totality itself in its most fundamental state, the concept of all mighty, revealed in ancient philosophical texts of Hinduism.

Etymology and meaning
साक्षी or शाक्षी means 'observer', 'eyewitness' or the 'Supreme Being', is the Atman, the unchangeable eternal Reality, Pure Consciousness and knowledge. It is the timeless Being which witnesses all this ceaseless flow and change in the world of thought and things, the 'Witness' or the higher 'Ego', the faculty which perceives the individual personality.

It lends its shine (Chitchhaya) to the "ego" part of the subtle body, which consists of the everchanging Mind, the decision making Intellect, the Memory & the Illusory Ego.

Upanishads
With regard to the word, साक्षी (sākṣī), used in the following verse from Shvetashvatara Upanishad,

एको देवः सर्वभूतेषु गूढः सर्वव्यापी सर्वभूतान्तरात्मा |
कर्माध्यक्षः सर्वभूताधिवासः साक्षी चेता केवलो निर्गुणश्च ||

"The Lord is hidden in the hearts of all. 
The eternal witness, pure consciousness, 
He watches our work from within, beyond 
The reach of the gunas (attributes of mind)." 
(Shvetashvatara Upanishad Sl. VI.11, translated by Eknath Easwaran)

The Varaha Upanishad (IV) refers to the Bhumika ('stage of development of wisdom') which is of the form of pranava (Aum or Om) as formed of or divided into – akāra, ukāra, makāra and ardhmātra, which is on account of the difference of sthula ('gross'), sukshama ('subtle'), bija ('seed' or 'causal') and sakshi ('witness') whose avasthas ('states') are – 'waking', 'dreaming', 'dream-less sleep' and 'turiya'. Sakshi which is 'turiya' is the essence.

Panini
Panini states that the same indicates a direct seer or eyewitness (Panini Sutras V.ii.91), Sakshi means Ishvara, the चेता (cetā), the sole Self-consciousness, who is the witness of all, who gives consciousness to every human being, thereby making each rational and discriminatory.

Vedanta
Vedanta speaks of mind (chitta) or antahkarana ('internal instrument'), and matter as the subtle and gross forms of one and the same reality; being the subtle aspect of matter, mind is not a tangible reality. The field of mind (Chittakasha) involves the duality of the seer and the seen, the observer (drg) and the observed (drshya), which duality is overcome in the field of pure Consciousness. Drg-drshya-Viveka tells us:

"When form is the object of observation or drshyam, then the eye is the observer or drk; when the eye is the object of observation, then the mind is the observer; when the pulsations of the mind are the objects of observation, then Sakshi or the Witnessing-Self is the real observer; and it is always the observer, and, being self-luminous, can never be the object of observation. When the notion and the attachment that one is the physical body is dissolved, and the Supreme Self is realized, wherever one goes, there one experiences Samadhi. "

Sankara explains that knowledge does not destroy or create, it only illumines, that the senses (indriyas) are not the mind, the mind uses them as an implement.

Swami Sarvapriyananda explains it like this:

"See, this table is an object of experience to my eyes. My eyes and the body are objects of experience to my mind. And my mind is an object of experience, I cannot deny it, it's a fact ...to what? That awareness which experiences the mind from within. That awareness which cannot be objectified. That is called, for want of a better term, because it witnesses, it shines upon, illumines every movement of the mind, every thought, every idea, every memory, every feeling, it's called the Witness. In Sanskrit: sakshi."

References

Hindu philosophical concepts
Language and mysticism
Sanskrit words and phrases
Vedanta