<div contenteditable="true" id="test">bu bir deneme yazısıdır..</div>

Fare imleç pozisyonu: <span id="position"></span>
#test {
  padding: 10px;
  border: 1px solid #ddd;
  margin-bottom: 10px;
}
$('#test').on('click', function(){
  var sel = window.getSelection();
  $('#position').text( sel.extentOffset );
})

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

  1. https://cdnjs.cloudflare.com/ajax/libs/jquery/2.1.3/jquery.min.js